원클릭으로
run-test
Guide for executing Sagittarius tests. Use this when asked to execute tests.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Guide for executing Sagittarius tests. Use this when asked to execute tests.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Guide for writing Sagittarius documents. Use this when asked to write a user reference manual or other Sagittarius documents.
Guide for developing Scheme libraries for Sagittarius. Use this when creating or modifying Scheme libraries in sitelib/, implementing SRFI, or adding new utility libraries.
Guide for developing Sagittarius compiler. Use this when you need to develop or optimize the compiler.
| name | run-test |
| description | Guide for executing Sagittarius tests. Use this when asked to execute tests. |
Sagittarius' tests can be executed via ctest command
Use the command below to execute full test
ctest --output-on-failure -j 6
The value of the -j option can be changed. It's better not to exceed the
number of CPU core.
CAUTION
The full test may take up to 10 minutes. The heavy tests contains crypto
in its name.
Executing individual tests has multiple options.
Using -R option filters the tests by name.
Example command
ctest --output-on-failure -R sagittarius
This executes the tests whose name contain sagittarius
Using -I option executes the specific range of the test
Example: execute tests for even numbers until 50
ctest --output-on-failure -I 2,50,2
Use this command to check the name and test number
ctest -N
You can run the test by using sagittarius command as well.
./build/sagittarius -Llib -Lsitelib -L'ext/*' -Dbuild test/runner.scm {test-file}
The test files are located in test/ directly.
The command can be used to execute other Scheme files, if you want to check outside of the tests.
Example: run continuation tests
./build/sagittarius -Llib -Lsitelib -L'ext/*' -Dbuild test/runner.scm \
test/tests/sagittarius/continuations.scm
When the tests failed, then you may see some patterns. Below are some of the example pattern that showing test failures
Example 1: unexpected failures
%%%% Starting test {test name}
FAIL {test unit name 1}
expected value: ...
actual value: ...
FAIL {test unit name 2}
expected value: ...
actual value: ...
FAIL {test unit name 3}
expected value: ...
actual value: ...
# of expected passes 16
# of unexpected failures 3
You clearly see test failures
Example 2: no output
%%%% Starting test {test name}
The summary of the tests is missing. This means either test hanged or application is finished unexpectedly
Example 3: SEGV You'll see native stack trace when SEGV happened.
When the code change happens, you might need to clear the cache file. You can use the command below to clear the cache.
./build/sagittarius -c -e '(exit)'
IMPORTANT
Make sure you use -e option with (exit) expression to exit the
application, otherwise the application goes into REPL, and waits for
the input.
You can execute a Scheme script directly by passing expressions via
-e command.
Example: say hello
./build/sagittarius -Llib -Lsitelib -L'ext/*' -Dbuild \
-e '(display "hello")(newline)(exit)'
IMPORTANT
The same rule as the cleanup cache file command is applied here.
Make sure the last expression is (exit).