Sweet
Sweet is a full-stack test framework for Rust. Use a single framework for some or all of the supported test types:
Type | Description |
---|---|
Native - Unit | Results-not-panic workflow |
Native - E2E | Full support for webdriver, fantoccini etc |
In-browser - Component | Test indivudual web components, framework agnostic |
In-browser - E2E | Run e2e tests on actual elements via iframes |
The in-browser tests are architecturally similar to Cypress Component and e2e tests. The native tests may be be compared to the likes of Jest or Playwright.
Features
- 🔥 Parallel
- 🕙 Async
- 🕸️ Native & In-Browser
- 🌍 E2E Tests
- ☮️ Intuitive matchers
- 🌈 Pretty output
Usage
#[sweet_test]
fn true_is_true() -> Result<()> {
expect(true).to_be_true()
}
Very Quick Start
git clone https://github.com/mrchantey/sweet-demo.git
cd sweet-demo
cargo run --example sweet
Getting Started
Check out the quickstart page or have a browse of the tests written for sweet
Overview
Sweet has four main components: