Opened 2 years ago

Closed 2 years ago

#19854 closed New feature (fixed)

Selenium tests in Django's own test suite should be off by default, flag to enable

Reported by: carljm Owned by: zsiciarz
Component: Testing framework Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The Django test suite includes a number of Selenium tests, mostly for testing the admin.

Currently these tests are automatically run if Selenium is installed, and not otherwise.

This is irritating, because I often don't want to run those tests (because they are very slow, and more prone to spurious breakage), but sometimes I do. Currently this means I have to repeatedly "pip install selenium" / "pip uninstall selenium", or else duplicate every Django-development virtualenv (of which I have seven, for Python 2.4/2.5/2.6/2.7/3.2/3.3) for a with-selenium and without-selenium version.

Instead, I think there should be a test-runner flag or an environment variable to explicitly disable running the Selenium tests even when Selenium is installed. (Or maybe have the default be not run them, and provide the flag to run them; I have no strong opinion on that.)

Change History (6)

comment:1 Changed 2 years ago by carljm

  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 2 years ago by zsiciarz

  • Owner changed from nobody to zsiciarz
  • Status changed from new to assigned
  • Version changed from 1.4 to master

comment:3 Changed 2 years ago by zsiciarz

  • Has patch set

comment:4 Changed 2 years ago by Honza Král <Honza.Kral@…>

  • Resolution set to fixed
  • Status changed from assigned to closed

In a05ab448f7a738d30ee7e8a513a65b6a67e8ea8e:

Merge pull request #781 from zsiciarz/ticket_19854

Fixed #19854 -- Added test runner option to skip Selenium tests

comment:5 Changed 2 years ago by carljm

  • Resolution fixed deleted
  • Status changed from closed to new
  • Summary changed from There should be an explicit flag to turn on/off Selenium tests in Django's own test suite to Selenium tests in Django's own test suite should be off by default, flag to enable

Julien, Anssi and I had discussed this on IRC and agreed that the Selenium tests should be off by default and require a flag to enable, but we failed to record that conclusion here. Re-opening until we make that change.

comment:6 Changed 2 years ago by Carl Meyer <carl@…>

  • Resolution set to fixed
  • Status changed from new to closed

In 906dc8522a1745e0e12c8061e4170540f7d0f486:

Fixed #19854 -- Turn Django's own Selenium tests off by default.

Note: See TracTickets for help on using tickets.
Back to Top