c-repl/test/operators.cpp

21 lines
387 B
C++
Raw Normal View History

2024-01-12 14:10:23 +01:00
#include "include/test.hpp"
2023-12-15 14:25:39 +01:00
2024-01-12 14:10:23 +01:00
#include "../src/include/execute.hpp"
#include "../src/include/utils.hpp"
2023-12-15 14:25:39 +01:00
int execute(string s) {
2024-01-03 16:20:42 +01:00
Memory memory;
return get<int>(execute(split_string(s, '\n'), memory));
2023-12-15 14:25:39 +01:00
}
int main() {
_TEST_PRESENTATION("Opérateurs");
_TEST_ASSERT(
_TEST_NO_EXCEPTION(execute("1,2;") == 2),
"Virgule",
true
);
return 0;
}