]> source.dussan.org Git - redmine.git/commitdiff
Rename test/fixtures/configuration/*.yml.example to test/fixtures/files/configuration...
authorGo MAEDA <maeda@farend.jp>
Sat, 10 Jul 2021 08:47:19 +0000 (08:47 +0000)
committerGo MAEDA <maeda@farend.jp>
Sat, 10 Jul 2021 08:47:19 +0000 (08:47 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@21067 e93f8b46-1217-0410-a6f0-8f06a7374b81

test/fixtures/configuration/default.yml.example [deleted file]
test/fixtures/configuration/empty.yml.example [deleted file]
test/fixtures/configuration/no_default.yml.example [deleted file]
test/fixtures/configuration/overrides.yml.example [deleted file]
test/fixtures/files/configuration/default.yml [new file with mode: 0644]
test/fixtures/files/configuration/empty.yml [new file with mode: 0644]
test/fixtures/files/configuration/no_default.yml [new file with mode: 0644]
test/fixtures/files/configuration/overrides.yml [new file with mode: 0644]
test/unit/lib/redmine/configuration_test.rb

diff --git a/test/fixtures/configuration/default.yml.example b/test/fixtures/configuration/default.yml.example
deleted file mode 100644 (file)
index 89a60f1..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-default:
-  somesetting: foo
-  
-production:
-
-development:
-
-test:
diff --git a/test/fixtures/configuration/empty.yml.example b/test/fixtures/configuration/empty.yml.example
deleted file mode 100644 (file)
index f280431..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-default:
-
-production:
-
-development:
-
-test:
diff --git a/test/fixtures/configuration/no_default.yml.example b/test/fixtures/configuration/no_default.yml.example
deleted file mode 100644 (file)
index 161224a..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-default:
-  
-production:
-
-development:
-
-test:
-  somesetting: foo
diff --git a/test/fixtures/configuration/overrides.yml.example b/test/fixtures/configuration/overrides.yml.example
deleted file mode 100644 (file)
index d9be392..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-default:
-  somesetting: foo
-  
-production:
-
-development:
-
-test:
-  somesetting: bar
diff --git a/test/fixtures/files/configuration/default.yml b/test/fixtures/files/configuration/default.yml
new file mode 100644 (file)
index 0000000..89a60f1
--- /dev/null
@@ -0,0 +1,8 @@
+default:
+  somesetting: foo
+  
+production:
+
+development:
+
+test:
diff --git a/test/fixtures/files/configuration/empty.yml b/test/fixtures/files/configuration/empty.yml
new file mode 100644 (file)
index 0000000..f280431
--- /dev/null
@@ -0,0 +1,7 @@
+default:
+
+production:
+
+development:
+
+test:
diff --git a/test/fixtures/files/configuration/no_default.yml b/test/fixtures/files/configuration/no_default.yml
new file mode 100644 (file)
index 0000000..161224a
--- /dev/null
@@ -0,0 +1,8 @@
+default:
+  
+production:
+
+development:
+
+test:
+  somesetting: foo
diff --git a/test/fixtures/files/configuration/overrides.yml b/test/fixtures/files/configuration/overrides.yml
new file mode 100644 (file)
index 0000000..d9be392
--- /dev/null
@@ -0,0 +1,9 @@
+default:
+  somesetting: foo
+  
+production:
+
+development:
+
+test:
+  somesetting: bar
index b33de6e436e18a54336fc3071261e2abb283d7b5..2647fb7b83bd34d7bd57c57bb63fec3c010c7957 100644 (file)
@@ -25,26 +25,26 @@ class Redmine::ConfigurationTest < ActiveSupport::TestCase
   end
 
   def test_empty
-    assert_kind_of Hash, load_conf('empty.yml.example', 'test')
+    assert_kind_of Hash, load_conf('empty.yml', 'test')
   end
 
   def test_default
-    assert_kind_of Hash, load_conf('default.yml.example', 'test')
+    assert_kind_of Hash, load_conf('default.yml', 'test')
     assert_equal 'foo', @conf['somesetting']
   end
 
   def test_no_default
-    assert_kind_of Hash, load_conf('no_default.yml.example', 'test')
+    assert_kind_of Hash, load_conf('no_default.yml', 'test')
     assert_equal 'foo', @conf['somesetting']
   end
 
   def test_overrides
-    assert_kind_of Hash, load_conf('overrides.yml.example', 'test')
+    assert_kind_of Hash, load_conf('overrides.yml', 'test')
     assert_equal 'bar', @conf['somesetting']
   end
 
   def test_with
-    load_conf('default.yml.example', 'test')
+    load_conf('default.yml', 'test')
     assert_equal 'foo', @conf['somesetting']
     @conf.with 'somesetting' => 'bar' do
       assert_equal 'bar', @conf['somesetting']
@@ -56,7 +56,7 @@ class Redmine::ConfigurationTest < ActiveSupport::TestCase
 
   def load_conf(file, env)
     @conf.load(
-      :file => File.join(Rails.root, 'test', 'fixtures', 'configuration', file),
+      :file => file_fixture(File.join('configuration', file)),
       :env => env
     )
   end