Initial Commit
This commit is contained in:
commit
e64361c864
10 files changed
+17815
No files matched your search
@@ -0,0 +1,5 @@
|
||||
project(tests)
|
||||
file(GLOB UNIT_TESTS unit_*.cpp)
|
||||
file(GLOB INTEGRATION_TESTS int_*.cpp)
|
||||
add_executable(tests main.cpp ${UNIT_TESTS} ${INTEGRATION_TESTS})
|
||||
target_link_libraries(tests daggy)
|
||||
+17698
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,9 @@
|
||||
#include <iostream>
|
||||
|
||||
#include "daggy/DAG.hpp"
|
||||
|
||||
#include "catch.hpp"
|
||||
|
||||
TEST_CASE("General tests", "[general]") {
|
||||
REQUIRE(1 == 1);
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
#include <iostream>
|
||||
|
||||
#include "daggy/DAG.hpp"
|
||||
|
||||
#define CATCH_CONFIG_MAIN
|
||||
#include "catch.hpp"
|
||||
|
||||
TEST_CASE("Sanity tests", "[sanity]") {
|
||||
REQUIRE(1 == 1);
|
||||
}
|
||||
|
||||
// compile and run
|
||||
// g++ -std=c++17 -o test test.cpp && ./test
|
||||
@@ -0,0 +1,14 @@
|
||||
#include <iostream>
|
||||
|
||||
#include "daggy/DAG.hpp"
|
||||
|
||||
#include "catch.hpp"
|
||||
|
||||
TEST_CASE("DAG Basic Tests", "[dag]") {
|
||||
daggy::DAG<int, std::string> dag;
|
||||
|
||||
dag.addVertex(0, "hello");
|
||||
dag.addVertex(1, "goodbye");
|
||||
|
||||
dag.addEdge(0, 1);
|
||||
}
|
||||
Reference in new issue
Block a user