Skip to content

Commit 821ffc4

Browse files
committed
Updated the readme and script for generating new excercises
1 parent f1c0c04 commit 821ffc4

3 files changed

Lines changed: 15 additions & 2 deletions

File tree

‎exercises/foundations/01_hello_world/README.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,14 @@ In this directory you'll find 2 other files:
77
1. `hello_world.py`
88
2. `test_hello_world.py`
99

10-
Run the test from the root directory (python-exercises):
10+
Run the test from the root directory (`python-exercises`):
1111
**Note:** try `python3` if the command fails
1212

1313
```bash
1414
python check.py 01
1515
```
16-
or
16+
17+
Full path syntax is also supported (with TAB completions working)
1718
```bash
1819
python check.py foundations/01_hello_world
1920
```

‎exercises/foundations/02_datatypes/README.md‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,11 @@ You need to define the following variables:
1414

1515
You need to make sure the variables are named **exactly** like written here, otherwise the tests will fail, values can be anything you want.
1616

17+
### Run the tests
18+
To run the tests, run the following command in the directory root (`python-excercises`):
19+
```bash
20+
python check.py 02
21+
```
22+
1723
## Notes
1824
To finish this excercise, visit our first lesson in TPL - [Datatypes](https://thepythonledger.github.io/Docusaurus-engine/lessons/python-foundations/core-datatypes)

‎scripts/new_exercise.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,12 @@ def test_{func_name}_placeholder():
6666
top-level code, no functions needed. Say what the script should print
6767
(or which variables it should end up with).
6868
69+
### Run the tests
70+
To run the tests, run the following command in the directory root (`python-excercises`):
71+
```bash
72+
python check.py {number:02d}
73+
```
74+
6975
## Notes
7076
7177
TODO: mention any edge cases, hints, or background concepts a learner

0 commit comments

Comments
 (0)