Handle ActiveRecord::DatabaseConnectionError #7
GitHub Actions / Rspec Tests - Rails 7.0 - mysql
succeeded
Jan 8, 2024 in 0s
Rspec Tests - Rails 7.0 - mysql ✅
✅ test_results/rspec.xml
96 tests were completed in 2s with 96 passed, 0 failed and 0 skipped.
Test suite | Passed | Failed | Skipped | Time |
---|---|---|---|---|
rspec | 96✅ | 2s |
✅ rspec
spec.unit.persistent_enum_spec
✅ PersistentEnum refuses to create a table in a transaction
✅ PersistentEnum with an enum model returns all values from the database
✅ PersistentEnum with an enum model is immutable
✅ PersistentEnum with an enum model behaves like acts like a persisted enum looks up each value
✅ PersistentEnum with an enum model behaves like acts like a persisted enum returns all values from the cache
✅ PersistentEnum with an enum model behaves like acts like a persisted enum a referring model can be created from enum value
✅ PersistentEnum with an enum model behaves like acts like a persisted enum a referring model can be created from constant name
✅ PersistentEnum with an enum model behaves like acts like a persisted enum a referring model can be created from ordinal
✅ PersistentEnum with an enum model behaves like acts like a persisted enum a referring model can be created with null foreign key
✅ PersistentEnum with an enum model behaves like acts like a persisted enum a referring model can not be created with invalid foreign key
✅ PersistentEnum with an enum model behaves like acts like a persisted enum a referring model can not be created with invalid foreign constant
✅ PersistentEnum with a validation on the model does not admit invalid values
✅ PersistentEnum with a validation on the model with existing invalid values does not admit invalid values
✅ PersistentEnum with a table-less enum behaves like falls back to a dummy model without rake defined raises the error directly
✅ PersistentEnum with a table-less enum behaves like falls back to a dummy model with rake defined warns that it is falling back
✅ PersistentEnum with a table-less enum behaves like falls back to a dummy model with rake defined makes a dummy model
✅ PersistentEnum with a table-less enum behaves like falls back to a dummy model with rake defined initializes dummy values correctly
✅ PersistentEnum with a table-less enum with rake defined behaves like acts like an enum looks up each value
✅ PersistentEnum with a table-less enum with rake defined behaves like acts like an enum returns all values from the cache
✅ PersistentEnum with existing data caches required values
✅ PersistentEnum with existing data caches all values
✅ PersistentEnum with existing data loads all values
✅ PersistentEnum with existing data caches required ordinals
✅ PersistentEnum with existing data caches all ordinals
✅ PersistentEnum with existing data loads all ordinals
✅ PersistentEnum with existing data respects initial value
✅ PersistentEnum with existing data respects existing value
✅ PersistentEnum with existing data marks existing model as non-active
✅ PersistentEnum with existing data behaves like acts like a persisted enum looks up each value
✅ PersistentEnum with existing data behaves like acts like a persisted enum returns all values from the cache
✅ PersistentEnum with existing data behaves like acts like a persisted enum a referring model can be created from enum value
✅ PersistentEnum with existing data behaves like acts like a persisted enum a referring model can be created from constant name
✅ PersistentEnum with existing data behaves like acts like a persisted enum a referring model can be created from ordinal
✅ PersistentEnum with existing data behaves like acts like a persisted enum a referring model can be created with null foreign key
✅ PersistentEnum with existing data behaves like acts like a persisted enum a referring model can not be created with invalid foreign key
✅ PersistentEnum with existing data behaves like acts like a persisted enum a referring model can not be created with invalid foreign constant
✅ PersistentEnum with cached constants caches all the constants
✅ PersistentEnum with complex constant names caches the constant name as we expect
✅ PersistentEnum with extra fields warns if nonexistent attributes are provided
✅ PersistentEnum with extra fields providing a hash keeps outdated data
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum looks up each value
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum returns all values from the cache
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum a referring model can be created from enum value
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum a referring model can be created from constant name
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum a referring model can be created from ordinal
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum a referring model can be created with null foreign key
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum a referring model can not be created with invalid foreign key
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum a referring model can not be created with invalid foreign constant
✅ PersistentEnum with extra fields providing a hash behaves like acts like a persisted enum with extra fields has all expected members with expected values
✅ PersistentEnum with extra fields providing a hash when reinitializing uses the same constant
✅ PersistentEnum with extra fields providing a hash when reinitializing handles a change in an attribute
✅ PersistentEnum with extra fields providing a hash when reinitializing handles a change in enum constant by replacing
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum looks up each value
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum returns all values from the cache
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum a referring model can be created from enum value
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum a referring model can be created from constant name
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum a referring model can be created from ordinal
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum a referring model can be created with null foreign key
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum a referring model can not be created with invalid foreign key
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum a referring model can not be created with invalid foreign constant
✅ PersistentEnum with extra fields using builder interface behaves like acts like a persisted enum with extra fields has all expected members with expected values
✅ PersistentEnum with extra fields with closed over builder can reinitialize with a changed value
✅ PersistentEnum with extra fields without table behaves like falls back to a dummy model without rake defined raises the error directly
✅ PersistentEnum with extra fields without table behaves like falls back to a dummy model with rake defined warns that it is falling back
✅ PersistentEnum with extra fields without table behaves like falls back to a dummy model with rake defined makes a dummy model
✅ PersistentEnum with extra fields without table behaves like falls back to a dummy model with rake defined initializes dummy values correctly
✅ PersistentEnum with extra fields without table with rake defined behaves like acts like an enum looks up each value
✅ PersistentEnum with extra fields without table with rake defined behaves like acts like an enum returns all values from the cache
✅ PersistentEnum with extra fields without table with rake defined behaves like acts like an enum with extra fields has all expected members with expected values
✅ PersistentEnum with extra fields with missing required attributes behaves like falls back to a dummy model without rake defined raises the error directly
✅ PersistentEnum with extra fields with missing required attributes behaves like falls back to a dummy model with rake defined warns that it is falling back
✅ PersistentEnum with extra fields with missing required attributes behaves like falls back to a dummy model with rake defined makes a dummy model
✅ PersistentEnum with extra fields with missing required attributes behaves like falls back to a dummy model with rake defined initializes dummy values correctly
✅ PersistentEnum with extra fields with missing required attributes with rake defined warns that the required attributes were missing
✅ PersistentEnum with extra fields with attributes with defaults allows defaults to be omitted
✅ PersistentEnum with extra fields with attributes with defaults with non-default existing values asserts the defaults when omitted
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum looks up each value
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum returns all values from the cache
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum a referring model can be created from enum value
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum a referring model can be created from constant name
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum a referring model can be created from ordinal
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum a referring model can be created with null foreign key
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum a referring model can not be created with invalid foreign key
✅ PersistentEnum with the name of the enum value column changed behaves like acts like a persisted enum a referring model can not be created with invalid foreign constant
✅ PersistentEnum without an index on the enum constant behaves like falls back to a dummy model without rake defined raises the error directly
✅ PersistentEnum without an index on the enum constant behaves like falls back to a dummy model with rake defined warns that it is falling back
✅ PersistentEnum without an index on the enum constant behaves like falls back to a dummy model with rake defined makes a dummy model
✅ PersistentEnum without an index on the enum constant behaves like falls back to a dummy model with rake defined initializes dummy values correctly
✅ PersistentEnum without an index on the enum constant with rake defined warns that the unique index was missing
✅ PersistentEnum without a unique index on the enum constant behaves like falls back to a dummy model without rake defined raises the error directly
✅ PersistentEnum without a unique index on the enum constant behaves like falls back to a dummy model with rake defined warns that it is falling back
✅ PersistentEnum without a unique index on the enum constant behaves like falls back to a dummy model with rake defined makes a dummy model
✅ PersistentEnum without a unique index on the enum constant behaves like falls back to a dummy model with rake defined initializes dummy values correctly
✅ PersistentEnum without a unique index on the enum constant with rake defined warns that the unique index was missing
✅ PersistentEnum with an empty constants array looks up the existing value
✅ PersistentEnum with an empty constants array caches the existing value
Loading