From bb6b87a2685c0d71b5c38be33c100f85ac0b9cee Mon Sep 17 00:00:00 2001 From: Renaud G Date: Thu, 25 Jul 2019 09:59:29 +0200 Subject: Rework of the component to be a proper lib --- tests/dice/CMakeLists.txt | 3 +++ tests/dice/tst_dice.cpp | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/dice/CMakeLists.txt b/tests/dice/CMakeLists.txt index 4065cc5..fef1a7b 100644 --- a/tests/dice/CMakeLists.txt +++ b/tests/dice/CMakeLists.txt @@ -5,5 +5,8 @@ find_package(Qt5Test REQUIRED) set(test_source testnode.cpp tst_dice.cpp) add_executable(test_dice ${test_source} ) + +target_include_directories(test_dice PRIVATE ../../include) + target_link_libraries(test_dice diceparser Qt5::Test) add_test(tst_diceparser test_dice) diff --git a/tests/dice/tst_dice.cpp b/tests/dice/tst_dice.cpp index 1fe2641..4da3474 100644 --- a/tests/dice/tst_dice.cpp +++ b/tests/dice/tst_dice.cpp @@ -524,7 +524,7 @@ void TestDice::keepTest() if(error) return; - auto resultScore= keepN.getResult()->getResult(Result::SCALAR).toInt(); + auto resultScore= keepN.getResult()->getResult(Dice::RESULT_TYPE::SCALAR).toInt(); QCOMPARE(score, resultScore); } @@ -609,7 +609,7 @@ void TestDice::countTest() node.run(nullptr); - QCOMPARE(score, countN.getResult()->getResult(Result::SCALAR).toInt()); + QCOMPARE(score, countN.getResult()->getResult(Dice::RESULT_TYPE::SCALAR).toInt()); countN.setValidator(nullptr); } -- cgit v1.2.3-70-g09d2