I've adapted marcgibbons/django-selenium-docker replacing
unittestwithpytestwith the help ofpytest-django
-
Install
docker -
Launch selenium & django
docker-compose up
-
Open
localhost:7900in your browser to viewSeleniumin action. Password issecretselenium/standalone-chromeusesNoVNCto hook into the runningseleniumbrowser -
Hook in to the running Django container and run the tests
docker exec django bash pytest