active_text 0.0.7 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/active_text.gemspec +1 -1
- data/lib/active_text/base.rb +2 -1
- data/spec/active_text_spec.rb +6 -10
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.8
|
data/active_text.gemspec
CHANGED
data/lib/active_text/base.rb
CHANGED
@@ -66,7 +66,8 @@ module ActiveText
|
|
66
66
|
variable.value
|
67
67
|
end
|
68
68
|
else
|
69
|
-
|
69
|
+
Rails.logger.debug("Could not find #{method_name} among these variables: #{@variables.inspect}")
|
70
|
+
raise NoMethodError, %Q(Method "#{method_name}" does not exist)
|
70
71
|
end
|
71
72
|
end
|
72
73
|
|
data/spec/active_text_spec.rb
CHANGED
@@ -105,19 +105,15 @@ $mbc: #555;}
|
|
105
105
|
// @description Background image.
|
106
106
|
$mbc2: "http://someurl.com/image.jpg";
|
107
107
|
|
108
|
-
// @name
|
108
|
+
// @name Dark color
|
109
109
|
// @kind color
|
110
|
-
// @description
|
111
|
-
$
|
110
|
+
// @description This is the dark color all throughout the site.
|
111
|
+
$blue_gray: #5f7081;
|
112
|
+
}
|
112
113
|
@s = ActiveText::Base.new(text)
|
113
|
-
@s.update_attributes(:mbc2 => %Q("Another URL"),
|
114
|
+
@s.update_attributes(:mbc2 => %Q("Another URL"), "blue_gray" => "#444")
|
114
115
|
@s.mbc2.should == %Q("Another URL")
|
115
|
-
@s.
|
116
|
-
# even after reinstantiation
|
117
|
-
@s = ActiveText::Base.new(text)
|
118
|
-
@s.update_attributes({"mbc" => "#444"})
|
119
|
-
@s.mbc2.should == %Q("http://someurl.com/image.jpg")
|
120
|
-
@s.mbc.should == "#444"
|
116
|
+
@s.blue_gray.should == "#444"
|
121
117
|
end
|
122
118
|
|
123
119
|
it "should have setter method for variables" do
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_text
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 15
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 8
|
10
|
+
version: 0.0.8
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Ramon Tayag
|