https://github.com/mfunyu/tester_philosophers
Tester for level 3 project "philosophers" @42Tokyo
https://github.com/mfunyu/tester_philosophers
42cursus dining-philosophers-problem tester
Last synced: 29 days ago
JSON representation
Tester for level 3 project "philosophers" @42Tokyo
- Host: GitHub
- URL: https://github.com/mfunyu/tester_philosophers
- Owner: mfunyu
- Created: 2021-10-05T12:58:41.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2022-05-25T04:30:19.000Z (over 3 years ago)
- Last Synced: 2025-03-04T06:22:27.991Z (7 months ago)
- Topics: 42cursus, dining-philosophers-problem, tester
- Language: Python
- Homepage: https://github.com/mfunyu/philosophers
- Size: 43 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# tester_philosophers
> ⚠️ Important notes :
> - Colored log format may not be supported for some tests.
> - Failing this test does not necessary mean your philosopher fails to meet the requirements.
> Reference: https://discord.com/channels/691903146909237289/691908977918738453/881739363719979009 (Private link for 42Tokyo students)# Installation
```
git clone https://github.com/mfunyu/tester_philosophers.git &&
python3 -m pip install pyparsing
```
### Directory structure
```
── philosophers
├── Makefile
├── includes
├── srcs
└── tester_philosophers
```# Usage
### run all tests
```shell
./tester_philosophers/test.sh
```
### display help
```
$> ./tester_philosophers/test.sh help
Call test.sh with a cmd arg to exec single test
./test.sh arg: [check wrong arguments]
./test.sh time: [check chronology of timestamps]
./test.sh retval: [check return values]
./test.sh advanced: [visualize fork and check for more detailded conditions]
```
### run advanced test- add command-line arguments as the same order from `./philo`
```
./tester_philosophers/run.sh [philo_nbs] [death_time] [eat_time] [sleep_time]
```