smart_slug 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +3 -3
- data/lib/smart_slug.rb +0 -1
- data/lib/smart_slug/version.rb +2 -2
- data/spec/smart_slug_spec.rb +3 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 336db30bbd2039b2e2216d751ebe45a6aaecf0d6
|
4
|
+
data.tar.gz: 2d42e2cc3a0e8e9e1be5a590a010e9ca149c53f5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f40f1f9eadb0158e91ceb65fb616b50ef5a0762feb2f9b93d2d8119501fb947acecbb2b7475b699267017919a8896c1d5f5b4b1ead3de5efa740e257f2222539
|
7
|
+
data.tar.gz: 0bb9f503d1a73fce4ab12667b39a1b41c08d3cea8cc9f798527e565881c98980c25d7dacbe2e1bb2c8c39286b38c6359b183af2435d7cab2ca96c474ce3c35bf
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -16,12 +16,12 @@ And then execute:
|
|
16
16
|
require 'smart_slug'
|
17
17
|
|
18
18
|
slug = SmartSlug.new(" Coração ")
|
19
|
-
=> #<SmartSlug:0x007ff0c20907a8 @original=" Coração ", @slug="
|
19
|
+
=> #<SmartSlug:0x007ff0c20907a8 @original=" Coração ", @slug="Coracao">
|
20
20
|
|
21
21
|
slug.to_s
|
22
|
-
=> "
|
22
|
+
=> "Coracao"
|
23
23
|
|
24
|
-
slug == '
|
24
|
+
slug == 'Coracao'
|
25
25
|
=> true
|
26
26
|
```
|
27
27
|
|
data/lib/smart_slug.rb
CHANGED
data/lib/smart_slug/version.rb
CHANGED
@@ -1,3 +1,3 @@
|
|
1
|
-
|
2
|
-
VERSION = "0.0.
|
1
|
+
class SmartSlug
|
2
|
+
VERSION = "0.0.2"
|
3
3
|
end
|
data/spec/smart_slug_spec.rb
CHANGED
@@ -4,14 +4,14 @@ require 'spec_helper'
|
|
4
4
|
describe SmartSlug do
|
5
5
|
let(:smart_slug) { SmartSlug.new(' Coração Valente ')}
|
6
6
|
describe :to_s do
|
7
|
-
it { expect(smart_slug.to_s).to eq("
|
7
|
+
it { expect(smart_slug.to_s).to eq("Coracao-Valente") }
|
8
8
|
end
|
9
9
|
describe :== do
|
10
|
-
it { expect(smart_slug == '
|
10
|
+
it { expect(smart_slug == 'Coracao-Valente').to be_true }
|
11
11
|
end
|
12
12
|
it "does not change variabled passed" do
|
13
13
|
var = "Coração"
|
14
|
-
expect(SmartSlug.new(var).to_s).to eq("
|
14
|
+
expect(SmartSlug.new(var).to_s).to eq("Coracao")
|
15
15
|
expect(var).to eq("Coração")
|
16
16
|
end
|
17
17
|
end
|