Fixed formatting
This commit is contained in:
@@ -31,10 +31,10 @@ TEST_CASE("t20001")
|
||||
REQUIRE(MessageOrder(src,
|
||||
{
|
||||
//
|
||||
{"tmain()", "A", "A()"}, //
|
||||
{"tmain()", "A", "A()"}, //
|
||||
{"tmain()", "B", "B(A &)"}, //
|
||||
|
||||
{"tmain()", "A", "add(int,int)"}, //
|
||||
{"tmain()", "A", "add(int,int)"}, //
|
||||
|
||||
{"tmain()", "B", "wrap_add3(int,int,int)"}, //
|
||||
{"B", "A", "add3(int,int,int)"}, //
|
||||
|
||||
@@ -37,4 +37,4 @@ TEST_CASE("t20014")
|
||||
{"C<B,int>", "B", "b1(int,int)"}, //
|
||||
}));
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -30,7 +30,7 @@ TEST_CASE("t20015")
|
||||
}));
|
||||
|
||||
REQUIRE(!HasMessage(src, {"B", {"detail", "A"}, "set_x(int)"}));
|
||||
REQUIRE(!HasMessage(src, {"B", {"detail" ,"A"}, "set_y(int)"}));
|
||||
REQUIRE(!HasMessage(src, {"B", {"detail", "A"}, "set_y(int)"}));
|
||||
REQUIRE(!HasMessage(src, {"B", {"detail", "A"}, "set_z(int)"}));
|
||||
|
||||
REQUIRE(!HasMessage(src, {"B", "B", "set_x(int)"}));
|
||||
|
||||
@@ -30,7 +30,7 @@ TEST_CASE("t20019")
|
||||
{"tmain()", "Base<D1>", "name()"}, //
|
||||
{"Base<D1>", "D1", "impl()"}, //
|
||||
{"tmain()", "Base<D2>", "name()"}, //
|
||||
{"Base<D2>", "D2", "impl()"} //
|
||||
{"Base<D2>", "D2", "impl()"} //
|
||||
}));
|
||||
});
|
||||
}
|
||||
@@ -32,7 +32,7 @@ TEST_CASE("t20022")
|
||||
// properly
|
||||
{"tmain()", "A", "A(std::unique_ptr<B>)"}, //
|
||||
{"tmain()", "A", "a()"}, //
|
||||
{"A", "B", "b()"}, //
|
||||
{"A", "B", "b()"}, //
|
||||
}));
|
||||
});
|
||||
}
|
||||
@@ -33,59 +33,13 @@ TEST_CASE("t20037")
|
||||
{"a()", "B", "get()"}, //
|
||||
{"a()", "c()", ""}, //
|
||||
|
||||
// {"tmain(int,char **)", "a()", ""}, //
|
||||
// {"a()", "B", "get()"}, //
|
||||
// {"a()", "c()", ""}, //
|
||||
//
|
||||
// {"tmain(int,char **)", "a()", ""}, //
|
||||
// {"a()", "B", "get()"}, //
|
||||
// {"a()", "c()", ""} //
|
||||
{"tmain(int,char **)", "a()", ""}, //
|
||||
{"a()", "B", "get()"}, //
|
||||
{"a()", "c()", ""}, //
|
||||
|
||||
{"tmain(int,char **)", "a()", ""}, //
|
||||
{"a()", "B", "get()"}, //
|
||||
{"a()", "c()", ""} //
|
||||
}));
|
||||
});
|
||||
/*
|
||||
{
|
||||
auto src = generate_sequence_puml(diagram, *model);
|
||||
AliasMatcher _A(src);
|
||||
|
||||
REQUIRE_THAT(src, StartsWith("@startuml"));
|
||||
REQUIRE_THAT(src, EndsWith("@enduml\n"));
|
||||
|
||||
REQUIRE_THAT(src, HasCall(_A("tmain(int,char **)"), _A("a()"), ""));
|
||||
REQUIRE_THAT(src, HasCall(_A("a()"), _A("initb()"), ""));
|
||||
REQUIRE_THAT(src, HasCall(_A("a()"), _A("B"), "get()"));
|
||||
REQUIRE_THAT(src, HasCall(_A("a()"), _A("c()"), ""));
|
||||
|
||||
save_puml(config.output_directory(), diagram->name + ".puml", src);
|
||||
}
|
||||
|
||||
{
|
||||
auto j = generate_sequence_json(diagram, *model);
|
||||
|
||||
using namespace json;
|
||||
|
||||
std::vector<int> messages = {
|
||||
FindMessage(j, "tmain(int,char **)", "a()", ""),
|
||||
FindMessage(j, "a()", "initb()", ""),
|
||||
FindMessage(j, "a()", "B", "get()"),
|
||||
FindMessage(j, "a()", "c()", "")};
|
||||
|
||||
REQUIRE(std::is_sorted(messages.begin(), messages.end()));
|
||||
|
||||
save_json(config.output_directory(), diagram->name + ".json", j);
|
||||
}
|
||||
|
||||
{
|
||||
auto src = generate_sequence_mermaid(diagram, *model);
|
||||
|
||||
mermaid::SequenceDiagramAliasMatcher _A(src);
|
||||
using mermaid::HasCall;
|
||||
|
||||
REQUIRE_THAT(src, HasCall(_A("tmain(int,char **)"), _A("a()"), ""));
|
||||
REQUIRE_THAT(src, HasCall(_A("a()"), _A("initb()"), ""));
|
||||
REQUIRE_THAT(src, HasCall(_A("a()"), _A("B"), "get()"));
|
||||
REQUIRE_THAT(src, HasCall(_A("a()"), _A("c()"), ""));
|
||||
|
||||
save_mermaid(config.output_directory(), diagram->name + ".mmd",
|
||||
src);
|
||||
}*/
|
||||
}
|
||||
@@ -25,7 +25,8 @@ TEST_CASE("t20046")
|
||||
|
||||
CHECK_SEQUENCE_DIAGRAM(config, diagram, *model, [](const auto &src) {
|
||||
REQUIRE(MessageOrder(src,
|
||||
{//
|
||||
{
|
||||
//
|
||||
{"tmain()", "tmain()::(lambda t20046.cc:13:15)",
|
||||
"operator()(auto &&) const"}, //
|
||||
{"tmain()::(lambda t20046.cc:13:15)",
|
||||
|
||||
@@ -248,7 +248,8 @@ void try_run_test_case(const diagram_source_storage &diagrams, TC &&tc)
|
||||
std::cout << "-----------------------------------------------------"
|
||||
"--------------------------\n";
|
||||
std::cout << "Test case failed for diagram type "
|
||||
<< T::diagram_type_name << ": " << "\n\n";
|
||||
<< T::diagram_type_name << ": "
|
||||
<< "\n\n";
|
||||
std::cout << diagrams.get<T>().to_string() << "\n";
|
||||
|
||||
throw e;
|
||||
@@ -610,7 +611,6 @@ void CHECK_INCLUDE_DIAGRAM(const clanguml::config::config &config,
|
||||
#include "t20052/test_case.h"
|
||||
#include "t20053/test_case.h"
|
||||
|
||||
|
||||
///
|
||||
/// Package diagram tests
|
||||
///
|
||||
|
||||
@@ -51,8 +51,6 @@ using namespace clanguml::util;
|
||||
std::pair<clanguml::config::config, clanguml::common::compilation_database_ptr>
|
||||
load_config(const std::string &test_name);
|
||||
|
||||
//void save_puml(const std::string &path, const std::string &puml);
|
||||
|
||||
namespace clanguml::test {
|
||||
|
||||
template <typename T, typename... Ts> constexpr bool has_type() noexcept
|
||||
|
||||
Reference in New Issue
Block a user