Skip to content

qawatake/obsidian-e2e-sample

Repository files navigation

Obsidian E2E Sample

ci

This repository provides a sample setup for end-to-end testing of Obsidian plugins using Playwright. It is based on the approach developed by proog in their obsidian-trash-explorer plugin, and extends it by automating the setup process to make testing possible in CI environments.

Features

  • Works on macOS for local testing
  • Verified operation in GitHub Actions
  • Automates setup of Obsidian, test vault, and plugin
  • Uses Electron directly with unpacked Obsidian sources

How to Use

npm install
./scripts/setup-obsidian.sh # Unpacks and prepares Obsidian
npm run e2e:setup           # Creates a test vault and registers it to Obsidian
npm run e2e                 # Runs Playwright-based E2E tests

See ci.yml for details.

Acknowledgements

Based on the work in proog/obsidian-trash-explorer

About

Sample project of E2E testing for Obsidian plugins

Topics

Resources

License

Stars

Watchers

Forks