openwisp / django-rest-framework-gis

Geographic add-ons for Django REST Framework. Maintained by the OpenWISP Project.
http://openwisp.org
MIT License
1.09k stars 201 forks source link

updated tests.py for DRF 3.12 compatibilty. #243

Closed 0xethsign closed 4 years ago

0xethsign commented 4 years ago

updated tests.py for DRF 3.12 compatibilty.

TravisBuddy commented 4 years ago

Travis tests have failed

Hey @smrpn, Please read the following log in order to understand the failure reason. It'll be awesome if you fix what's wrong and commit the changes.

10th Build

View build log

./run-qa-checks ``` SUCCESS: Blank endline check successful! Skipped 1 files SUCCESS: Isort check successful! All done! ✨ 🍰 ✨ 27 files would be left unchanged. SUCCESS: Black check successful! SUCCESS: Flake8 check successful! Your commit message does not follow our commit message style guidelines: - missing prefix in the commit short description Eg: "[feature/fix/change] Action performed" Please read our guidelines at: http://openwisp.io/docs/developer/contributing.html#commit-message-style-guidelines Checked commit message: Merge branch 'smrpn' of https://github.com/smrpn/django-rest-framework-gis into smrpn ERROR: Commit message check failed! ```
tox -e travis ``` travis create: /home/travis/build/openwisp/django-rest-framework-gis/.tox/travis travis installdeps: djangorestframework~=3.10, -rrequirements-test.txt travis develop-inst: /home/travis/build/openwisp/django-rest-framework-gis travis installed: appdirs==1.4.4,asgiref==3.2.10,attrs==20.2.0,black==19.10b0,certifi==2020.6.20,chardet==3.0.4,click==7.1.2,contexttimer==0.3.3,coverage==5.3,coveralls==2.1.2,Django==3.1.2,django-filter==2.4.0,django-model-utils==4.0.0,djangorestframework==3.12.1,-e git+https://github.com/openwisp/django-rest-framework-gis.git@2d47da114b1ceb038993e0ef7f606168850ec674#egg=djangorestframework_gis,docopt==0.6.2,flake8==3.8.4,idna==2.10,isort==5.6.4,mccabe==0.6.1,openwisp-utils==0.6.3,pathspec==0.8.0,psycopg2==2.8.6,pycodestyle==2.6.0,pyflakes==2.2.0,pytz==2020.1,regex==2020.10.15,requests==2.24.0,sqlparse==0.4.1,toml==0.10.1,typed-ast==1.4.1,urllib3==1.25.10 travis run-test-pre: PYTHONHASHSEED='731333357' travis run-test: commands[0] | coverage run --source=rest_framework_gis ./tests/manage.py test tests/django_restframework_gis_tests Creating test database for alias 'default'... System check identified no issues (0 silenced). ..........................s.............Fs....../home/travis/build/openwisp/django-rest-framework-gis/.tox/travis/lib/python3.8/site-packages/rest_framework/pagination.py:200: UnorderedObjectListWarning: Pagination may yield inconsistent results with an unordered object_list: QuerySet. paginator = self.django_paginator_class(queryset, page_size) ............................ ====================================================================== FAIL: test_geojson_HTML_widget_value (django_restframework_gis_tests.tests.TestRestFrameworkGis) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/travis/build/openwisp/django-rest-framework-gis/tests/django_restframework_gis_tests/tests.py", line 534, in test_geojson_HTML_widget_value self.assertContains(response, '"type": "Point"') File "/home/travis/build/openwisp/django-rest-framework-gis/.tox/travis/lib/python3.8/site-packages/django/test/testcases.py", line 470, in assertContains self.assertTrue(real_count != 0, msg_prefix + "Couldn't find %s in response" % text_repr) AssertionError: False is not true : Couldn't find '"type": "Point"' in response ---------------------------------------------------------------------- Ran 76 tests in 0.823s FAILED (failures=1, skipped=2) Destroying test database for alias 'default'... free(): invalid pointer ERROR: InvocationError for command /home/travis/build/openwisp/django-rest-framework-gis/.tox/travis/bin/coverage run --source=rest_framework_gis ./tests/manage.py test tests/django_restframework_gis_tests (exited with code -6 (SIGABRT)) (exited with code -6) ___________________________________ summary ____________________________________ ERROR: travis: commands failed ```
TravisBuddy Request Identifier: 53ab1170-1109-11eb-bfd1-1f84b849c73d