Skip to content
Snippets Groups Projects

Issue #3357733: Provide Drush command to enforce configs

7 files
+ 126
0
Compare changes
  • Side-by-side
  • Inline
Files
7
+ 53
0
@drush-command
Feature: A Drush command to enforce configs
In order to reliably import configs from the filesystem
As a DevOps Engineer
I need to run a Drush command to enforce configs.
Background:
Given I run 'cd ..; make install'
Scenario: The `config-enforce:enforce` Drush command exists.
When I run 'drush list'
Then I should get:
"""
config-enforce:enforce
"""
When I run 'drush config-enforce:enforce --help'
Then I should get:
"""
Import any configuration that has changed from that on the filesystem.
Examples:
config-enforce:enforce Enforce configuration.
Aliases: cee
"""
When I run 'drush cee --help'
Then I should get:
"""
Import any configuration that has changed from that on the filesystem.
Examples:
config-enforce:enforce Enforce configuration.
Aliases: cee
"""
Scenario: A target module's optional configs are not imported when it is enabled.
When I am on the homepage
Then I should see "Config Enforce Devel"
And I should not see "Config Enforce Devel -- Test for Drush"
And I should not see "Drush command appears to work!"
When I run 'drush pm-enable -y ce_test_drush_command'
And I am on the homepage
Then I should see "Config Enforce Devel"
And I should not see "Config Enforce Devel -- Test for Drush"
And I should not see "Drush command appears to work!"
Scenario: Configs in a module's `config/optional` are imported when our Drush command is run.
When I run 'drush pm-enable -y ce_test_drush_command'
And I run 'drush config-enforce:enforce'
Then I should get:
"""
Config Enforce enforced configs.
"""
And I am on the homepage
Then I should see "Config Enforce Devel -- Test for Drush"
And I should see "Drush command appears to work!"
Loading