Capybara vs Mercurial
A source-aware comparison of pricing, documented capabilities and workflow fit.
Short answer
- Price: both start at Free.
- How to start: both are free.
- Where they differ: only Capybara has public api; both offer open source / self-hostable.
These lines are generated from the pricing we track, not from a paid placement. How we score tools.
What Capybara is
Capybara is an MIT-licensed Ruby library and acceptance-testing DSL that simulates user interaction with web applications. It supplies finders, matchers, actions, sessions and automatic waiting while delegating actual execution to drivers such as the fast RackTest default or browser-capable Selenium. It is not itself a browser, test runner or assertion framework, and test fidelity, JavaScript support, isolation and concurrency behavior depend on the chosen driver and surrounding stack.
What Mercurial is
Mercurial is GPL-licensed distributed source-control software in which each normal repository copy contains local project history for offline commits, branches and merges. The Python-based core can be extended with bundled or external extensions, but hosting, review workflows, identity, backups and CI are separate choices that must explicitly support Mercurial repositories.
Side by side
| Capybara | Mercurial | |
|---|---|---|
| Category | Developer Tools | Developer Tools |
| How to start | Freeverified | Freeverified |
| Public API | Yes | No |
| Mobile app | No | No |
| Open source / self-hostable | Yes | Yes |
| SSO (SAML) | No | No |
| Visit | Capybara ↗ | Mercurial ↗ |
What Capybara is built to do
- Navigation and actions
- Visits pages, fills fields, clicks controls, attaches files and manipulates supported browser state.
- Finders and matchers
- Queries accessible labels, text, CSS and XPath with configurable matching behavior.
- Automatic waiting
- Retries eligible queries and expectations while asynchronous content settles.
- Interchangeable drivers
- Routes the DSL through RackTest, Selenium or compatible external drivers with different capabilities.
What Mercurial is built to do
- Local repositories
- Keeps project history locally for offline commit, diff, branch and merge operations.
- Clone, pull and push
- Exchanges changesets between independently administered repositories.
- Named branches and bookmarks
- Provides multiple mechanisms for organizing lines and heads of development.
- Extensions
- Adds or changes commands through bundled, third-party or custom Python modules.
Choose Capybara if
- Ruby application journeys expressed through user-visible behavior
- Test suites that mix fast non-JavaScript coverage with selected real-browser scenarios
- Teams prepared to manage browser drivers, test data and asynchronous behavior
Skip Capybara if
- The test stack is not Ruby-based and gains no value from a Ruby DSL
- You expect the default RackTest driver to execute JavaScript or test a remote URL
- The suite lacks a strategy for database isolation, browser dependencies and flaky-state diagnosis
Choose Mercurial if
- Existing Mercurial codebases that need continued distributed version control
- Teams whose required host, CI and editor integrations explicitly support Mercurial
- Workflows that benefit from Mercurial's core command model and selected extensions
Skip Mercurial if
- A required hosting or delivery service supports only another version-control system
- Critical extensions are unmaintained or depend on unstable Mercurial internals
- You expect the core tool to include hosted reviews, identity management and backups
Evidence and freshness
Where a claim on this page comes from a vendor page, it is linked here.
Capybara
Official sources reviewed · reviewed 2026-08-24
Mercurial
Official sources reviewed · reviewed 2026-08-24
Capybara: pros & cons
- User-oriented DSL: Tests express visits, form actions, element queries and expectations close to browser behavior.
- Automatic synchronization: Finders and matchers wait up to configured limits for asynchronous page state.
- Driver portability: The same high-level API can run against RackTest, Selenium and compatible third-party drivers.
- Framework integration: Official guidance covers use with RSpec, Minitest and other Ruby test setups.
- Default driver has no JavaScript: RackTest is fast but cannot validate client-side behavior or interact with remote applications.
- Browser tests cost more: Selenium-style drivers add browser binaries, timing variability and infrastructure overhead.
- Thread and data isolation: Transactional database strategies may not share state with a separately threaded application server.
- Ambiguous selectors can fail: Capybara intentionally raises on multiple matches unless the query is made specific.
Mercurial: pros & cons
- Distributed operation: Developers can commit and inspect full local history without a central server connection.
- Consistent core interface: The project documents a compact command model with hazardous behavior moved behind opt-in extensions.
- Extension system: Bundled and external Python extensions can add commands or alter workflows.
- Active releases: The official project page lists maintained release notes through the current release line.
- Hosting not included: Access control, code review, issues and remote availability require hgweb or a compatible external service.
- Integration validation: Teams must confirm that chosen IDE, CI, deployment and hosting tools support Mercurial.
- Extension compatibility: Archived installation guidance warns that internal API changes can break extensions or dependent tools.
- Archived wiki risk: The former project wiki is explicitly marked discontinued and potentially outdated, so current docs take precedence.
Our verdict on Capybara
Choose Capybara for readable Ruby acceptance tests, but select drivers per scenario: keep RackTest where server-rendered behavior is enough and prove critical JavaScript journeys with a maintained browser driver and deterministic data isolation.
Our verdict on Mercurial
Choose Mercurial on verified workflow fit, not broad ecosystem assumptions; inventory every host, extension and CI integration, then test upgrades against that exact toolchain.