mirror of
https://github.com/open-goal/jak-project
synced 2026-07-29 07:33:59 -04:00
[goalc] add a build system (#704)
* add first attempt at build system * fix stupid bug * try again
This commit is contained in:
@@ -115,6 +115,10 @@ std::vector<std::string> get_test_pass_string(const std::string& name, int count
|
||||
}
|
||||
} // namespace
|
||||
|
||||
TEST_F(WithGameTests, MakeSystem) {
|
||||
compiler.run_front_end_on_string("(make \"out/iso/ENGINE.CGO\")");
|
||||
}
|
||||
|
||||
TEST_F(WithGameTests, ReturnConstant) {
|
||||
runner.run_static_test(env, testCategory, "defun-return-constant.static.gc", {"12\n"});
|
||||
}
|
||||
|
||||
@@ -1319,3 +1319,17 @@ TEST(GoosBuiltins, Error) {
|
||||
Interpreter i;
|
||||
EXPECT_ANY_THROW(e(i, "(error \"hi\")"));
|
||||
}
|
||||
|
||||
TEST(GoosBuiltins, Ash) {
|
||||
Interpreter i;
|
||||
EXPECT_EQ(e(i, "(ash 3 2)"), "12");
|
||||
EXPECT_EQ(e(i, "(ash 3 -1)"), "1");
|
||||
}
|
||||
|
||||
TEST(GoosBuiltins, StringUtils) {
|
||||
Interpreter i;
|
||||
EXPECT_EQ(e(i, "(string-ref \"test\" 2)"), "#\\s");
|
||||
EXPECT_EQ(e(i, "(string-length \"test\")"), "4");
|
||||
EXPECT_EQ(e(i, "(string-append \"hello\" \" \" \"world\")"), "\"hello world\"");
|
||||
EXPECT_EQ(e(i, "(symbol->string 'test)"), "\"test\"");
|
||||
}
|
||||
Reference in New Issue
Block a user