rails/railties/test/isolation
eileencodes 8f3066fccc Fix database configuration when adding another config level
This is kind of hard to explain but if you have a database config with
another level like this:

```
development:
  primary:
    database: "my db"
    variables:
      statement_timeout: 1000
```

the database configurations code would chooke on the `variables` level
because it didn't know what to do with it.

We'd see the following error:

```
lib/active_record/database_configurations.rb:72:in
`block in find_db_config': undefined method `env_name' for [nil]:Array
(NoMethodError)
```

The problem here is that Rails does correctly identify this as not a
real configuration but returns `[nil]` along with the others. We need to
make sure to flatten the array and remove all the `nil`'s before
returning the `configurations` objects.

Fixes #35646
2019-03-18 16:23:00 -04:00
..
assets Add missing packages (#35227) 2019-02-12 16:00:17 +09:00
abstract_unit.rb Fix database configuration when adding another config level 2019-03-18 16:23:00 -04:00