Open LFK01 opened 5 months ago
Hello @LFK01
Could you add pytest tests following this guide? https://click.palletsprojects.com/en/8.1.x/testing/
You can check for reference the existing tests in tests/unit_test/swapanything_test
Hi @ggbaro , I implemented the tests, let me know if everything adds up.
The command execution requires the package installation which can be obtained with the following command inside the cloned repository directory:
pip install -e .
The-e
flag allows the developer to change the code and observe the changes without reinstalling the package..
is the cloned repository directory where pip will search for thepyproject.toml
file.You can test the CLI with:
swapanything tests/unit_test/data/faker_availabilities.csv output.csv --headers --index-col --subject-col "Nome e Cognome" --slot-col "Availabilities"
It should print the selected matches in the file output.csv. Remember to delete or to exclude the file output.csv when committing to the branch or change its path to another position.