another_hola 0.0.1 → 0.0.2

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: 0acbcaece33e671b74a9521f622c495f2bf8ce0d
4
- data.tar.gz: 7ea23bc06fdec5eb0b9667a16837d2a22264a5af
3
+ metadata.gz: 85f77a62d82c10ab0dd46046b2c3979993221fa2
4
+ data.tar.gz: 7c36126b5b70d7f54f3feb80f56199efa8162b88
5
5
  SHA512:
6
- metadata.gz: 7b8f479d7d4dbe121a49d2ee7840fabac66aa1b0c9975fd2159f8f4d53490ffb03f26ac6bc762c7aad699c9bbc69129bae42dba3af8a1b19aefb00e331d80869
7
- data.tar.gz: 77f4b6fadf71f07bbf4d752a9642b41a5563c95888f6aedf73e92b07a64e0855bd24ae65d50adcdb2bf2684319c16b5ee602ce11ab2acef82e96c71c26de588d
6
+ metadata.gz: 02c4dd8023e39f80616b34a614cd3a3d154b42d603f71e234ad63bc335cb7b5c7fcc34f3ad7f4bcc301f701b0e553a2bdd86c069387e899609527dcfca22e308
7
+ data.tar.gz: 69509f65551070b3455e3526b2d4c1b41430f2b965c31ff72fb50308edbcee4cbb2bf453c84d2c1ffb6aca211eb02135af06c23e887f098801b7d647e1e50b2e
data/Rakefile ADDED
@@ -0,0 +1,8 @@
1
+ require 'rake/testtask'
2
+
3
+ Rake::TestTask.new do |t|
4
+ t.libs << 'test'
5
+ end
6
+
7
+ desc "Run tests"
8
+ task :default => :test
data/lib/another_hola.rb CHANGED
@@ -1,4 +1,14 @@
1
+ # The main AnotherHola driver
1
2
  class AnotherHola
3
+ # Say hi to the world!
4
+ #
5
+ # Example:
6
+ # >> AnotherHola.hi("spanish")
7
+ # => hola mundo
8
+ #
9
+ # Arguments:
10
+ # language: (String)
11
+
2
12
  def self.hi(language = "english")
3
13
  translator = Translator.new(language)
4
14
  translator.hi
@@ -0,0 +1,19 @@
1
+ require 'minitest/autorun'
2
+ require 'another_hola'
3
+
4
+ class AnotherHolaTest < Minitest::Test
5
+ def test_english_hello
6
+ assert_equal "hello world",
7
+ AnotherHola.hi("english")
8
+ end
9
+
10
+ def test_any_hello
11
+ assert_equal "hello world",
12
+ AnotherHola.hi("ruby")
13
+ end
14
+
15
+ def test_spanish_hello
16
+ assert_equal "hola mundo",
17
+ AnotherHola.hi("spanish")
18
+ end
19
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: another_hola
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Salsabila Nadhifah
@@ -17,9 +17,11 @@ executables:
17
17
  extensions: []
18
18
  extra_rdoc_files: []
19
19
  files:
20
+ - Rakefile
20
21
  - bin/another_hola
21
22
  - lib/another_hola.rb
22
23
  - lib/another_hola/translator.rb
24
+ - test/test_another_hola.rb
23
25
  homepage:
24
26
  licenses:
25
27
  - MIT
@@ -44,4 +46,5 @@ rubygems_version: 2.6.8
44
46
  signing_key:
45
47
  specification_version: 4
46
48
  summary: Another Hola!
47
- test_files: []
49
+ test_files:
50
+ - test/test_another_hola.rb