It’s critical to have this gems in group :development, :test do not just group :test do as
default commands like rails generate ... are running under development environment, therefore
they will not pick up default config overrides by this gems unless you run: RAILS_ENV=test rails generate ...

Faker

Sometimes you want to have random data in your tests (E.g. random email
address) as that helps you discover problems you would normally spot
only in production when real data starts pouring into your system.

Now again this is useless test not helping the developer much, I just want to show you that when you are dealing
with random data you cannot just compare whether the result equals a string. You
need to check if the result equals the state and type of an object.

You don’t want to have Random data all the time, I would even argue
that most of the time it’s healthier to work with dereministic data.
To understand why pls read this article