From 03e6c4184c32aea2429f3e64cfff0b5a301cf1aa Mon Sep 17 00:00:00 2001 From: Phil Lee Date: Mon, 14 Nov 2022 15:58:09 +0000 Subject: [PATCH] update docs on parallel testing --- docs/testing.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/docs/testing.md b/docs/testing.md index a453c69ca..57e40f747 100644 --- a/docs/testing.md +++ b/docs/testing.md @@ -15,3 +15,19 @@ nav_order: 4 - Feature specs are generally written sparingly as they’re also the slowest, where possible a request spec is preferred as this still tests a large surface area (route, controller, model, view) without the performance impact. They are not suitable for tests that need to run JavaScript or test that a specific set of interaction events that trigger a specific set of requests (with high confidence). - Test data is created with [FactoryBot](https://github.com/thoughtbot/factory_bot) where ever possible + +## Parallel testing + +- The RSpec test suite can be ran in parallel in local development for quicker turnaround times + +- Setup with the following: + +```sh +bundle exec rake parallel:setup +``` + +- Run with: + +```sh +RAILS_ENV=test bundle exec rake parallel:spec +```