Skip to content

Commit

Permalink
test cs < command
Browse files Browse the repository at this point in the history
  • Loading branch information
no-lex committed May 6, 2024
1 parent 55263df commit 46c5385
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions test/testcs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,50 @@ void test_cs_nequals()
test_cs_command(inputs, vals);
}

void test_cs_lessthan()
{
std::printf("testing CS < command\n");

std::vector<std::string> inputs = {
"< 1",
"< 0",
"< 1 1",
"< 0 1 2",
"< 0 1 0",
"< 1 0",
"<f 1",
"<f 0",
"<f 1 1",
"<f 0 1 2",
"<f 0 1 0",
"<f 1 0",
"<s test, test2",
"<s test2 test",
"<s test test2 test3",
"<s test test test"
};
std::vector<int> vals = {
0,
0,
0,
1,
0,
0,
0,
0,
0,
1,
0,
0,
1,
0,
1,
0
};

test_cs_command(inputs, vals);
}

//run tests
void testcs()
{
Expand All @@ -292,6 +336,7 @@ void testcs()
test_cs_minus();
test_cs_equals();
test_cs_nequals();
test_cs_lessthan();
//command.h
testescapestring();
testescapeid();
Expand Down

0 comments on commit 46c5385

Please sign in to comment.