active_text 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/README.textile +1 -1
- data/VERSION +1 -1
- data/active_text.gemspec +1 -1
- data/lib/active_text/base.rb +1 -1
- data/spec/active_text_spec.rb +3 -3
- metadata +3 -3
data/README.textile
CHANGED
@@ -37,7 +37,7 @@ You can also update the values:
|
|
37
37
|
<pre>
|
38
38
|
@at = ActiveText::Base.new(text_you_see_above)
|
39
39
|
@at.bg_image.value = "'/path/to/image.png'"
|
40
|
-
@at.
|
40
|
+
@at.apply # returns the text passed into base, with values replaced:
|
41
41
|
</pre>
|
42
42
|
|
43
43
|
<pre>
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.4
|
data/active_text.gemspec
CHANGED
data/lib/active_text/base.rb
CHANGED
data/spec/active_text_spec.rb
CHANGED
@@ -39,13 +39,13 @@ $mbc2: "http://someurl.com/image.jpg";}
|
|
39
39
|
@s.mbc2.value = %Q("Another URL")
|
40
40
|
@s.mbc2.value.should == %Q("Another URL")
|
41
41
|
|
42
|
-
rendered_text = @s.
|
42
|
+
rendered_text = @s.apply
|
43
43
|
rendered_text.should_not match(/http:\/\/someurl\.com\/image\.jpg/)
|
44
44
|
rendered_text.should match(/\$mbc2: "Another URL";/)
|
45
45
|
|
46
46
|
@s.mbc2.value = %Q("Some third URL")
|
47
47
|
@s.mbc2.value.should == %Q("Some third URL")
|
48
|
-
rendered_text = @s.
|
48
|
+
rendered_text = @s.apply
|
49
49
|
rendered_text.should_not match(/\$mbc2: "Another URL";/)
|
50
50
|
rendered_text.should match(/\$mbc2: "Some third URL";/)
|
51
51
|
end
|
@@ -61,7 +61,7 @@ $mbc2: "http://someurl.com/image.jpg";}
|
|
61
61
|
$mbc2: "Another URL";}
|
62
62
|
@s = ActiveText::Base.new(text_old)
|
63
63
|
@s.mbc2.value = %Q("Another URL")
|
64
|
-
@s.
|
64
|
+
@s.apply.should == text_new
|
65
65
|
end
|
66
66
|
end
|
67
67
|
|
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: 23
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 4
|
10
|
+
version: 0.0.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Ramon Tayag
|