Commit 4e79e648 authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Another attempt to correctly find tests dataset on CI

parent 1ee07f60
Pipeline #181436 failed with stage
in 5 minutes and 32 seconds
include_directories(${MLT_INCLUDE_DIR} ${MLTPP_INCLUDE_DIR} ..)
set(TEST_SOURCES ${CMAKE_CURRENT_SOURCE_DIR})
configure_file(tests_definitions.h.in tests_definitions.h)
kde_enable_exceptions()
add_executable(runTests
TestMain.cpp
......
......@@ -41,8 +41,8 @@ TEST_CASE("Cut undo/redo", "[MoveClips]")
int tid4 = TrackModel::construct(timeline);
// Create clip with audio (40 frames long)
//QString binId = createAVProducer(profile_move, binModel);
QString binId = createProducerWithSound(profile_move, binModel, 100);
QString binId = createAVProducer(profile_move, binModel);
//QString binId = createProducerWithSound(profile_move, binModel, 100);
// Setup insert stream data
QMap <int, QString>audioInfo;
......
......@@ -23,7 +23,6 @@ QString createProducer(Mlt::Profile &prof, std::string color, std::shared_ptr<Pr
QString createProducerWithSound(Mlt::Profile &prof, std::shared_ptr<ProjectItemModel> binModel, int length)
{
// std::shared_ptr<Mlt::Producer> producer = std::make_shared<Mlt::Producer>(prof, QFileInfo(QCoreApplication::applicationDirPath() + "/../../tests/small.mkv").absoluteFilePath().toStdString().c_str());
// In case the test system does not have avformat support, we can switch to the integrated blipflash producer
std::shared_ptr<Mlt::Producer> producer = std::make_shared<Mlt::Producer>(prof, "blipflash");
REQUIRE(producer->is_valid());
......@@ -44,7 +43,7 @@ QString createProducerWithSound(Mlt::Profile &prof, std::shared_ptr<ProjectItemM
QString createAVProducer(Mlt::Profile &prof, std::shared_ptr<ProjectItemModel> binModel)
{
std::shared_ptr<Mlt::Producer> producer = std::make_shared<Mlt::Producer>(prof, QFileInfo(QCoreApplication::applicationDirPath() + "/../../tests/small.mkv").absoluteFilePath().toStdString().c_str());
std::shared_ptr<Mlt::Producer> producer = std::make_shared<Mlt::Producer>(prof, QFileInfo(sourcesPath + "/small.mkv").absoluteFilePath().toStdString().c_str());
// In case the test system does not have avformat support, we can switch to the integrated blipflash producer
/*if (!producer->is_valid()) {
......@@ -63,7 +62,7 @@ QString createAVProducer(Mlt::Profile &prof, std::shared_ptr<ProjectItemModel> b
QString createTextProducer(Mlt::Profile &prof, std::shared_ptr<ProjectItemModel> binModel, int length)
{
std::shared_ptr<Mlt::Producer> producer = std::make_shared<Mlt::Producer>(prof, QFileInfo(QCoreApplication::applicationDirPath() + "/../../tests/dataset/title.kdenlivetitle").absoluteFilePath().toStdString().c_str());
std::shared_ptr<Mlt::Producer> producer = std::make_shared<Mlt::Producer>(prof, QFileInfo(sourcesPath + "/dataset/title.kdenlivetitle").absoluteFilePath().toStdString().c_str());
REQUIRE(producer->is_valid());
......
......@@ -2,6 +2,7 @@
#include "abortutil.hpp"
#include "bin/model/markerlistmodel.hpp"
#include "catch.hpp"
#include "tests_definitions.h"
#include "doc/docundostack.hpp"
#include <iostream>
#include <memory>
......
static const QString sourcesPath("@TEST_SOURCES@");
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment