Skip to content

Document custom LiveServerTestCase host for remote browsers#184

Merged
bittner merged 1 commit into
mainfrom
docs/customize-live-server-host
Jun 3, 2026
Merged

Document custom LiveServerTestCase host for remote browsers#184
bittner merged 1 commit into
mainfrom
docs/customize-live-server-host

Conversation

@bittner

@bittner bittner commented Jun 3, 2026

Copy link
Copy Markdown
Member

Summary

  • Adds a "Remote browsers and Selenium Hub" section to docs/webbrowser.rst showing how to subclass BehaviorDrivenTestCase with a custom host / port and select it via the --runner option.
  • Covers the use case from Add support for customized LiveServerTestCase with selenium-hub support #124: driving the live server from a Selenium Hub (or any browser running in a separate container / on a different host).
  • Includes a worked splinter example pointing at http://selenium-hub:4444/wd/hub and a note about ALLOWED_HOSTS.

No code changes — the pattern already works with the existing extension points (testcase_class on a runner subclass + Django's LiveServerTestCase.host / .port). This PR just makes that discoverable so #124 can be closed with a pointer to the docs.

Test plan

  • tox -e docs builds without warnings
  • Rendered HTML spot-checked: section appears in the TOC and the --runner cross-link resolves to configuration.html#runner

@bittner bittner force-pushed the docs/customize-live-server-host branch 2 times, most recently from 8bec399 to 6e468da Compare June 3, 2026 22:22
@bittner bittner requested a review from Copilot June 3, 2026 22:27
@bittner bittner self-assigned this Jun 3, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds documentation explaining how to run browser-based tests against a Django live test server from a browser running on a different host/container (e.g., via Selenium Grid / Hub), using existing BehaviorDrivenTestCase extension points and --runner.

Changes:

  • Adds a “Remote browsers and Selenium Hub” section to docs/webbrowser.rst.
  • Documents subclassing BehaviorDrivenTestCase to override LiveServerTestCase.host / .port, and selecting it via --runner.
  • Includes a worked Splinter Remote WebDriver example and an ALLOWED_HOSTS note.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/webbrowser.rst
Add a "Remote browsers and Selenium Hub" section to the webbrowser docs
showing how to subclass BehaviorDrivenTestCase with a custom host/port
and select it via --runner. This is the pattern requested in #124 for
driving the live server from a Selenium Hub or other out-of-host browser.
@bittner bittner force-pushed the docs/customize-live-server-host branch from a9e5db3 to 6f086b3 Compare June 3, 2026 22:45
@bittner bittner merged commit d1a650c into main Jun 3, 2026
13 checks passed
@bittner bittner deleted the docs/customize-live-server-host branch June 3, 2026 22:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants