coolify_gem 0.0.1 → 0.1.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7ed11fe62e8eeab524ab0a0126348140b473506c
4
- data.tar.gz: 4c2b4e640f6edd630ae5eb9faa22ec82057cd5d9
3
+ metadata.gz: 8d223b1eb84eb8a10438c3094359d8b8f65bcc03
4
+ data.tar.gz: 8c76d053cc34a4d8c020bf18c339e4bcb7fc4c26
5
5
  SHA512:
6
- metadata.gz: de8cdb139ceb5b58ff656b812fe295457021224a27d080911b894a029e39f480bdd3860321ad5869e1a120c82adba5770aa0f19bc6bb272c62eba8b3c7b277e6
7
- data.tar.gz: 6c798181adfc3dd7a66c8904304f0a788b9589e9a24a6d06294bf231c05e026338c8de28f10253ef20e1f752621f4e51835ca04f15be8b219a252b5d02f20e5a
6
+ metadata.gz: e91283a770753cc847a844fee7e675c5afff37add36319a5ff9f2fa1646f8fe0de371eb7f0688ab88caaeecbe6e719065577658a016a5b6a30a8a22a67f05e98
7
+ data.tar.gz: d531690feb195379ca4971839a04bdf015e18da95f3e7e4300f126c2ad2e61bb7e7a0ba3be296352808216916f7f9aecd8d0db10c295c9cbe12f1ae10dfe30ae
data/README.md CHANGED
@@ -20,9 +20,7 @@ Or install it yourself as:
20
20
 
21
21
  CoolifyGem will only work with strings. To use the gem, call the coolify method on a string in the following way:
22
22
 
23
- String.coolify – i.e. "Thiz ztring iz an example".coolify
24
-
25
- Output: "This string is an example"
23
+ "Thiz iz my firzt gem called Coolify!" , "This is my first gem called Coolify!".coolify
26
24
 
27
25
  ## Contributing
28
26
 
data/bin/cool ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'coolify_gem'
4
+ puts Cool.coolify(ARGV[0])
@@ -0,0 +1,11 @@
1
+ class Cool::Coolify
2
+
3
+ def initialize(text = "Tezt")
4
+ @text = text
5
+ end
6
+
7
+ def coolify
8
+ @text.gsub("s", "z")
9
+ end
10
+
11
+ end
@@ -1,3 +1,3 @@
1
1
  module CoolifyGem
2
- VERSION = "0.0.1"
2
+ VERSION = "0.1.0"
3
3
  end
data/lib/coolify_gem.rb CHANGED
@@ -1,6 +1,10 @@
1
1
  require "coolify_gem/version"
2
- require "coolify_gem/string"
3
2
 
4
- module CoolifyGem
5
- # Your code goes here...
3
+ class Cool
4
+ def self.coolify(text)
5
+ cooltext = Coolify.new(text)
6
+ cooltext.coolify
7
+ end
6
8
  end
9
+
10
+ require "coolify_gem/coolify"
@@ -1,7 +1,19 @@
1
1
  require "test_helper"
2
2
 
3
3
  class CoolifyTest < Test::Unit::TestCase
4
+ def test_blank
5
+ assert_equal "", Cool.coolify("")
6
+ end
7
+
8
+ def test_hi
9
+ assert_equal "hi", Cool.coolify("hi")
10
+ end
11
+
12
+ def test_switch_characters
13
+ assert_equal "z", Cool.coolify("s")
14
+ end
15
+
4
16
  def test_coolify
5
- assert_equal "Thiz iz my firzt gem called Coolify!" , "This is my first gem called Coolify!".coolify
17
+ assert_equal "Thiz iz my firzt gem called Coolify!" , Cool.coolify("This is my first gem called Coolify!")
6
18
  end
7
19
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: coolify_gem
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Carlos Zaragoza
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-23 00:00:00.000000000 Z
11
+ date: 2014-06-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -41,7 +41,8 @@ dependencies:
41
41
  description: This gem was created thanks to a YouTube tutorial by user Lasse Bunk.
42
42
  email:
43
43
  - Carlos.Marx421@gmail.com
44
- executables: []
44
+ executables:
45
+ - cool
45
46
  extensions: []
46
47
  extra_rdoc_files: []
47
48
  files:
@@ -50,9 +51,10 @@ files:
50
51
  - LICENSE.txt
51
52
  - README.md
52
53
  - Rakefile
54
+ - bin/cool
53
55
  - coolify_gem.gemspec
54
56
  - lib/coolify_gem.rb
55
- - lib/coolify_gem/string.rb
57
+ - lib/coolify_gem/coolify.rb
56
58
  - lib/coolify_gem/version.rb
57
59
  - test/coolify_gem_test.rb
58
60
  - test/test_helper.rb
@@ -1,5 +0,0 @@
1
- class String
2
- def coolify
3
- self.gsub("s", "z")
4
- end
5
- end