RSpec::FileFixtures provides a helper named fixture
available in all specs. This method receives a filename as a string and the provided file is loaded from spec/fixtures/
.
Fetch the fixture’s path:
Read the fixture’s content:
A number of extensions are provided to assist dealing with common data types. See each item in the Usage section for details.