RECETOX / RIAssigner

RIAssigner is a python tool for retention index (RI) computation for GC-MS data.
MIT License
4 stars 6 forks source link

Consider switching to tox.ini to run tests #85

Open cthoyt opened 2 years ago

cthoyt commented 2 years ago

I was reading through the CI configuration and it seems like a lot of complicated steps are required to run the tests. I'd suggest using something like tox to create a tox.ini file that simplifies the installation of the code and running of the tests and various other tasks like flake8, linting, etc.

Here's an example from one of my projects https://github.com/cthoyt/pystow/blob/main/tox.ini that lets you run tox -e py to run the unit tests from the command line and it takes care of making a virtual env and installing the right dependencies

hechth commented 2 years ago

Unit tests can be run from command line from using pytest . if all dependencies are installed. The CI merely installs the dependencies.

The tox.ini also creates an environment it seems so it kind of replicates the conda environment.

hechth commented 2 years ago

@cthoyt Are you able to install the conda environment via conda create -f conda\environment-dev.yml?

Otherwise, you can install the requirements using the requirements.txt file and then run the tests using pytest . in the root folder of the repository.