spec/scss_lint/config_spec.rb in scss-lint-0.37.0 vs spec/scss_lint/config_spec.rb in scss-lint-0.38.0
- old
+ new
@@ -44,10 +44,11 @@
let(:default_file) { <<-FILE }
linters:
FakeConfigLinter:
enabled: true
+ list: [1, 2, 3]
OtherFakeConfigLinter:
enabled: false
FILE
subject { described_class.load(file_name) }
@@ -99,9 +100,21 @@
enabled: true
FILE
it 'returns a configuration equivalent to the default' do
subject.options.should == described_class.default.options
+ end
+ end
+
+ context 'with a config file setting a list value different from the default' do
+ let(:config_file) { <<-FILE }
+ linters:
+ FakeConfigLinter:
+ list: [4, 5, 6]
+ FILE
+
+ it 'overrides the default value with the new value' do
+ subject.options['linters']['FakeConfigLinter']['list'].should == [4, 5, 6]
end
end
context 'when a wildcard is used for a namespaced linter' do
let(:default_file) { <<-FILE }