oscarmlage / django-cruds-adminlte

django-cruds is simple drop-in django app that creates CRUD for faster prototyping
BSD 3-Clause "New" or "Revised" License
424 stars 81 forks source link

Changes to tox & tests #104

Closed telenieko closed 5 years ago

telenieko commented 5 years ago

Hi,

I started this to have the testsuite run on my computer (py37, django 2.2) but had to touch a few more things on the way.

This is a work in progress but I submit for review of the current work. Changes:

A few of the above are self explanatory and accessory to the main theme (make tox work again). On the rest:

The conf.py fix is because the current setup raises a warning, which the testsuite is asked to treat as an error. No more warning!

The call to sys.exit() is as it appears to be the recommended way of working, the other way being to return a test suite from the function which we can't because by that time the test suite has already been run. So simply exist, preventing to return None which would thrown an exception.

The dependencies reorg consists basically in moving the absolute requirements which were both in setup.py and requirements.txt to only setup.py (the version pins from requirements.txt are now in setup.py) which not only prevents duplication but allows tox to then replace the Django version.

Per #103, it looks like the minimum Django version is 2.0, hence the minimum python version is 3. I cleared up the pypi classifiers on that regard on a separate commit which can be reverted.

The end result is that now running "tox" will work. IT is setup for python 3.5, 3.6, 3.7 and Django 2.0 and 2.2. I chose those randomly pending #103. On the Django version i simple choose what made sense as it is not completely clear to me which versions are supported.

Work in progress: The coverage report is not yet working. I don't know why yet, will try again tomorrow!

marc

oscarmlage commented 5 years ago

As I was thinking on working in a separate branch for Python3 and newer Django versions I've already created the python3 branch. Since I've started (had not much time lately) there are some commits I think we should review to merge (or introduce) here too:

We can even cherry-pick the changes (partially or totally) once this merge is done, right?.

Also I would like to clear the way we should release according to the versions. I mean, stop working on improvements on Django-1.x compatible versions since 0.0.16 and move to Django-2 or work in separate branches or some other solution. What do you think? (probably we should discuss is as an issue, not in a PR)

telenieko commented 5 years ago

I have merged python3 branch so this PR is not based on that instead of master, so this could be merged into python3 now.

I will continue about the last paragraph on #103