Skip to content

Commit 444cd35

Browse files
committed
Include test setup instructions
1 parent 07cdb3c commit 444cd35

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

docs/INSTALLATION.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,39 @@ After completing the installation, you can verify if the CLI was installed succe
1111
godot --version
1212
```
1313

14+
## Installing the Exercism GDScript track test runner
15+
16+
You'll need [Godot installed][installation] correctly to use the test runner.
17+
18+
To build and test GDScript scripts for Exercism, Godot will be run in "headless" mode from the CLI.
19+
These instructions currently require Linux and bash.
20+
21+
### Step 1: Installing the overall test runner infrastructure
22+
23+
To set up for testing, clone [https://github.com/exercism/gdscript-test-runner][gdscript-test-runner] and move its contents to `/opt/exercism/gdscript/test-runner/`:
24+
25+
```sh
26+
git clone https://github.com/exercism/gdscript-test-runner.git
27+
sudo mv gdscript-test-runner/ /opt/exercism/gdscript/test-runner/
28+
```
29+
30+
### Step 2: Downloading the single-exercise test runner script
31+
32+
Assuming you have the `exercism` tool set up and have downloaded at least one GDScript exercise, it should have created an `exercism/gdscript` folder to house the exercises.
33+
Save [the test runner][test-local-gdscript-solution] in this folder and mark the file executable.
34+
35+
## Running tests
36+
37+
With the installation steps done, you should be able start from any exercise directory (e.g., `~/exercism/gdscript/two-fer`) and run the script (living one level up, in `../`) to test your local solution to that exercise:
38+
39+
```sh
40+
../test-local-gdscript-solution.sh
41+
```
42+
43+
[installation]: https://exercism.org/docs/tracks/gdscript/installation
44+
[gdscript-test-runner]: https://github.com/exercism/gdscript-test-runner
45+
[test-local-gdscript-solution]: https://raw.githubusercontent.com/exercism/gdscript-test-runner/refs/heads/main/bin/test-local-gdscript-solution.sh
46+
1447
## Using an IDE
1548

1649
For syntax checking of GDScript files from, for example, [Visual Studio Code][vscode], you'll need to keep the Godot GUI running with a project open in order to activate the debug server, and an extension like [godot-tools][godot-tools] installed and activated.

0 commit comments

Comments
 (0)