This README would normally document whatever steps are necessary to get the application up and running.
Things you may want to cover:
-
Ruby version
-
System dependencies
-
Configuration
-
Database creation
-
Database initialization
-
How to run the test suite
-
Services (job queues, cache servers, search engines, etc.)
-
Deployment instructions
-
JSON rspec
https://github.com/brooklynDev/airborne
expect_json- Tests the values of the JSON property values returnedexpect_json_types- Tests the types of the JSON property values returnedexpect_json_keys- Tests the existence of the specified keys in the JSON objectexpect_json_sizes- Tests the sizes of the JSON property values returned, also test if the values are arraysexpect_status- Tests the HTTP status code returnedexpect_header- Tests for a specified header in the responseexpect_header_contains- Partial match test on a specified header
https://github.com/thoughtbot/shoulda-matchers
allow_valuetests that an attribute is valid or invalid if set to one or more values. (Aliased as #allow_values.)have_secure_passwordtests usage of has_secure_password.validate_absence_oftests usage of validates_absence_of.validate_acceptance_oftests usage of validates_acceptance_of.validate_confirmation_oftests usage of validates_confirmation_of.validate_exclusion_oftests usage of validates_exclusion_of.validate_inclusion_oftests usage of validates_inclusion_of.validate_length_oftests usage of validates_length_of.validate_numericality_oftests usage of validates_numericality_of.validate_presence_oftests usage of validates_presence_of.
accept_nested_attributes_fortests usage of the accepts_nested_attributes_for macro.belong_totests your belongs_to associations.define_enum_fortests usage of the enum macro.have_and_belong_to_manytests your has_and_belongs_to_many associations.have_db_columntests that the table that backs your model has a specific column.have_db_indextests that the table that backs your model has an index on a specific column.have_manytests your has_many associations.have_onetests your has_one associations.have_readonly_attributetests usage of the attr_readonly macro.serializetests usage of the serialize macro.validate_uniqueness_oftests usage of validates_uniqueness_of.
filter_paramtests parameter filtering configuration.permittests that an action places a restriction on the params hash.redirect_totests that an action redirects to a certain location.render_templatetests that an action renders a template.render_with_layouttests that an action is rendered with a certain layout.rescue_fromtests usage of the rescue_from macro.respond_withtests that an action responds with a certain status code.routetests your routes.set_sessionmakes assertions on the session hash.set_flashmakes assertions on the flash hash.use_after_actiontests that an after_action callback is defined in your controller.use_around_actiontests that an around_action callback is defined in your controller.use_before_actiontests that a before_action callback is defined in your controller.
https://github.com/khamusa/rspec-graphql_matchers
have_a_field(field_name).of_type(valid_type)implement(interface_name, ...)have_a_return_field(field_name).returning(valid_type)have_an_input_field(field_name).of_type(valid_type)be_of_type(valid_type)accept_argument(argument_name).of_type(valid_type)