ominous 0.0.5 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/app/helpers/ominous/application_helper.rb +9 -9
- data/app/helpers/ominous/warnings_helper.rb +6 -6
- data/app/views/ominous/warnings/_list.html.erb +2 -2
- data/lib/ominous/version.rb +8 -1
- data/test/dummy/config/routes.rb +2 -0
- data/test/dummy/db/test.sqlite3 +0 -0
- data/test/dummy/log/development.log +236 -0
- data/test/dummy/log/test.log +1633 -0
- data/test/unit/helpers/ominous/warnings_helper_test.rb +18 -0
- metadata +2 -2
@@ -2,5 +2,23 @@ require 'test_helper'
|
|
2
2
|
|
3
3
|
module Ominous
|
4
4
|
class WarningsHelperTest < ActionView::TestCase
|
5
|
+
|
6
|
+
def setup
|
7
|
+
@warning = Ominous::Warning.find(1)
|
8
|
+
@closer = @warning.closers.first
|
9
|
+
end
|
10
|
+
|
11
|
+
def test_classes_for_when_closer_hidden
|
12
|
+
@closer.update_attribute(:start_hidden, true)
|
13
|
+
expected = 'closer start_hidden'
|
14
|
+
assert_equal(expected, ominous_classes_for(@closer))
|
15
|
+
end
|
16
|
+
|
17
|
+
def test_classes_for_when_closer_visible
|
18
|
+
@closer.update_attribute(:start_hidden, false)
|
19
|
+
expected = 'closer start_visible'
|
20
|
+
assert_equal(expected, ominous_classes_for(@closer))
|
21
|
+
end
|
22
|
+
|
5
23
|
end
|
6
24
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ominous
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-01
|
12
|
+
date: 2013-05-01 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|