Making automated testing for a Python lib using TravisCI

My Github link:jayyyin

setting up Travis with python can be a pain but as long as you follow some steps it should be quite painless

first determine if you're going to be using pytest, in my case I am since it seems like a good way to test things,

in the repo directory you'll need a .travis.yml containing the following:

second determine what your rootdir for pytest will be, in my case it's just called python

thirdly by default only filenames starting with test_ will be read into pytest or you'll get a no results when collecting files

to set things up I have a pytest.ini file in the root of the repo (the same directory as

within it is as follows:
testpaths = python

that tells pytest to look in the python directory (if you want to add more just separate them by spaces like so):

testpaths = directory1 directory2


Popular posts from this blog

#Python-dev: adding pathlike functionality

#Python-dev: Starting to contribute to (c)python

#Python-dev: First contribution to (c)python