html_terminator 2.0.0 → 2.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ed1a46465f0b8d627c1b92e47e232373f2dd71ec
4
- data.tar.gz: 717809ee3bd7bd73895f2b2a558c6335e720679c
3
+ metadata.gz: ae2bc36f5c3ad8c93eef68ad14e03bd02a70c293
4
+ data.tar.gz: a76bb0d79dfda9e9c9cf188d03d286ddfaa6ea6b
5
5
  SHA512:
6
- metadata.gz: 66c00ffa3ac6b4a8f5667bbd0ebef76d84d92bfad7bb922c1f71173dfc321df40364836db52e2d0af360f9ca83d05a4761f30265719fdd02c7cc353d8d788a4c
7
- data.tar.gz: 5e86b8127abfc48f721a25828f2684b61e3197b06a44383cf81d8f65c85fdc28e5e72b69698fe98d41fd8d6ade625eff1ba6e096b47d1c89b134f79be9580cc9
6
+ metadata.gz: 7eb8714c34c2a6555589ef7408fef0bde3649cf0545553c869a38261e50c6dac05eb359fda20a5fd35bafc2141cdcec9357e2e467dd321d034d44ca15d58cd92
7
+ data.tar.gz: 5ffe0f501c605ba12032d808f558b2e22eb48ae2679d36c5e42fba803e13c80526c80283a1dd465c3279ef66a7cbb62d9549294ddea3413ab8ed90b6fb142cd6
data/.travis.yml CHANGED
@@ -1,5 +1,4 @@
1
1
  script: bundle exec rspec
2
2
  language: ruby
3
3
  rvm:
4
- - 2.0.0
5
- - 1.9.3
4
+ - 2.0.0
@@ -1,3 +1,3 @@
1
1
  module HtmlTerminator
2
- VERSION = "2.0.0"
2
+ VERSION = "2.0.1"
3
3
  end
@@ -7,7 +7,7 @@ module HtmlTerminator
7
7
  :elements => []
8
8
  }
9
9
 
10
- def self.sanitize(val, config)
10
+ def self.sanitize(val, config = {})
11
11
  if val.is_a?(String)
12
12
  # Sanitize produces escaped content.
13
13
  # Unescape it to get the raw html
@@ -65,4 +65,11 @@ describe HtmlTerminator do
65
65
  @user.first_name = "Hello <flexbox></flexbox><hr><br><img>"
66
66
  @user.first_name.should == "Hello <flexbox></flexbox>"
67
67
  end
68
+
69
+ describe "#sanitize" do
70
+ it "strips out all html by default" do
71
+ val = HtmlTerminator.sanitize "<flexbox></flexbox><hr><br><img>"
72
+ val.should == ""
73
+ end
74
+ end
68
75
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: html_terminator
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steel Fu
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-01-29 00:00:00.000000000 Z
12
+ date: 2016-02-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler