Rails 5.1 runs system tests and regular tests with a single command

In Rails 5.1, you can run bin/rails testto run regular tests and bin/rails test:system. What is Rails an authorized way to run both at the same time?

+4
source share
4 answers

bin/rails test:system test

Task test:systemto testwill run both system and regular tests. However, the opposite order will only perform normal tests.

+1
source

At least from the official guide on guides, there seems to be no way to do this:

, bin/rails . , bin/rails: .

:

+1

If someone else is looking for an answer:

bin/rails test test/*

0
source

If you intend to run it using only $ rakeor $rake test, you can add a Rakefile to your file:

task test: 'test:system'

This will make "test: system" mandatory for the test task.

0
source

Source: https://habr.com/ru/post/1684122/


All Articles