Sweet

Sweet is a full-stack test framework for Rust. Use a single framework for some or all of the supported test types:

TypeDescription
Native - UnitResults-not-panic workflow
Native - E2EFull support for webdriver, fantoccini etc
In-browser - ComponentTest indivudual web components, framework agnostic
In-browser - E2ERun 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: