From 1000e4c51ad4ba6816b0a3356e6ecd6c911f5755 Mon Sep 17 00:00:00 2001 From: claudiob Date: Fri, 21 Nov 2014 12:33:44 -0800 Subject: Move test that depends on ActiveRecord This commit moves a test from `test/template` to `test/activerecord` since the test depends on ActiveRecord. This matches the documentation from [RUNNING_UNIT_TESTS](https://github.com/rails/rails/blob/f28d1ddd507174ac233b773cc4f35c3c05ad32e7/actionview/RUNNING_UNIT_TESTS.rdoc): > Test cases in the test/activerecord/ directory depend on having activerecord and sqlite3 installed. > If Active Record is not in actionview/../activerecord directory, or the sqlite3 rubygem is not installed, these tests are skipped. > Other tests are runnable from a fresh copy of actionview without any configuration. --- More details about this commit. All the tests starting with `require 'active_record_unit'` are already inside `test/activerecord`, except for the one test this commit moves. If you don't have `active_record` on your machine, the following command currently fails on master: ```bash ``` --- actionview/test/activerecord/debug_helper_test.rb | 8 ++++++++ actionview/test/template/debug_helper_test.rb | 8 -------- 2 files changed, 8 insertions(+), 8 deletions(-) create mode 100644 actionview/test/activerecord/debug_helper_test.rb delete mode 100644 actionview/test/template/debug_helper_test.rb (limited to 'actionview') diff --git a/actionview/test/activerecord/debug_helper_test.rb b/actionview/test/activerecord/debug_helper_test.rb new file mode 100644 index 0000000000..5609694cd5 --- /dev/null +++ b/actionview/test/activerecord/debug_helper_test.rb @@ -0,0 +1,8 @@ +require 'active_record_unit' + +class DebugHelperTest < ActionView::TestCase + def test_debug + company = Company.new(name: "firebase") + assert_match "name: firebase", debug(company) + end +end diff --git a/actionview/test/template/debug_helper_test.rb b/actionview/test/template/debug_helper_test.rb deleted file mode 100644 index 5609694cd5..0000000000 --- a/actionview/test/template/debug_helper_test.rb +++ /dev/null @@ -1,8 +0,0 @@ -require 'active_record_unit' - -class DebugHelperTest < ActionView::TestCase - def test_debug - company = Company.new(name: "firebase") - assert_match "name: firebase", debug(company) - end -end -- cgit v1.2.3