You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Unit tests: Don't use OpenShot.h header
- To prevent slow compiles of unit tests, replace all of the '#include "OpenShot.h"' invocations with includes of the individual headers actually needed by each test file. Revert "Unit tests: Don't use OpenShot.h header" This reverts commit e5cc4f8bf91fc60697996023a86dc618637f6161. Unit tests: Don't use OpenShot.h header - To prevent slow compiles of unit tests, replace all of the '#include "OpenShot.h"' invocations with includes of the individual headers actually needed by each test file.
This commit is contained in:
@@ -28,12 +28,17 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "CacheDisk.h"
|
||||
#include "CacheMemory.h"
|
||||
#include "Json.h"
|
||||
|
||||
#include <QDir>
|
||||
|
||||
using namespace openshot;
|
||||
|
||||
TEST(Cache_Default_Constructor)
|
||||
|
||||
@@ -28,6 +28,9 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <sstream>
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
|
||||
// Work around older versions of UnitTest++ without REQUIRE
|
||||
@@ -37,7 +40,11 @@
|
||||
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Clip.h"
|
||||
#include "Frame.h"
|
||||
#include "Fraction.h"
|
||||
#include "Timeline.h"
|
||||
#include "Json.h"
|
||||
|
||||
using namespace openshot;
|
||||
|
||||
@@ -255,4 +262,3 @@ TEST(Verify_Parent_Timeline)
|
||||
}
|
||||
|
||||
} // SUITE
|
||||
|
||||
|
||||
@@ -28,10 +28,15 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Color.h"
|
||||
#include "KeyFrame.h"
|
||||
#include "Json.h"
|
||||
|
||||
SUITE(Color) {
|
||||
|
||||
|
||||
@@ -31,9 +31,8 @@
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Coordinate.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
TEST(Coordinate_Default_Constructor)
|
||||
|
||||
@@ -28,11 +28,16 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
|
||||
#include "OpenShot.h"
|
||||
#include "DummyReader.h"
|
||||
#include "CacheMemory.h"
|
||||
#include "Fraction.h"
|
||||
#include "Frame.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
@@ -146,4 +151,4 @@ TEST (DummyReader_Invalid_Fake_Frame) {
|
||||
// Clean up
|
||||
cache.Clear();
|
||||
r.Close();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,10 +28,16 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <sstream>
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "FFmpegReader.h"
|
||||
#include "Frame.h"
|
||||
#include "Timeline.h"
|
||||
#include "Json.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
@@ -272,4 +278,3 @@ TEST(Verify_Parent_Timeline)
|
||||
}
|
||||
|
||||
} // SUITE(FFmpegReader)
|
||||
|
||||
|
||||
@@ -28,10 +28,16 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <sstream>
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "FFmpegWriter.h"
|
||||
#include "FFmpegReader.h"
|
||||
#include "Fraction.h"
|
||||
#include "Frame.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Fraction.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
@@ -29,10 +29,15 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <sstream>
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Frame.h"
|
||||
#include "Clip.h"
|
||||
#include "Fraction.h"
|
||||
|
||||
#include <QImage>
|
||||
|
||||
|
||||
@@ -28,15 +28,22 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <sstream>
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
|
||||
#ifdef USE_IMAGEMAGICK
|
||||
#include "ImageWriter.h"
|
||||
#include "ImageReader.h"
|
||||
#include "FFmpegReader.h"
|
||||
#include "Frame.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
#ifdef USE_IMAGEMAGICK
|
||||
SUITE(ImageWriter)
|
||||
{
|
||||
|
||||
|
||||
@@ -31,7 +31,10 @@
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "KeyFrame.h"
|
||||
#include "Coordinate.h"
|
||||
#include "Fraction.h"
|
||||
#include "Point.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
@@ -31,7 +31,10 @@
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Point.h"
|
||||
#include "Enums.h"
|
||||
#include "Coordinate.h"
|
||||
#include "Json.h"
|
||||
|
||||
SUITE(POINT) {
|
||||
|
||||
|
||||
@@ -28,10 +28,15 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "ReaderBase.h"
|
||||
#include "CacheBase.h"
|
||||
#include "Frame.h"
|
||||
#include "Json.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Settings.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
@@ -28,10 +28,19 @@
|
||||
* along with OpenShot Library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <sstream>
|
||||
#include <memory>
|
||||
#include <list>
|
||||
|
||||
#include "UnitTest++.h"
|
||||
// Prevent name clashes with juce::UnitTest
|
||||
#define DONT_SET_USING_JUCE_NAMESPACE 1
|
||||
#include "OpenShot.h"
|
||||
#include "Timeline.h"
|
||||
#include "Clip.h"
|
||||
#include "Frame.h"
|
||||
#include "Fraction.h"
|
||||
#include "effects/Blur.h"
|
||||
#include "effects/Negate.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
Reference in New Issue
Block a user