froyo_api 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/froyo_api.gemspec +3 -0
- data/lib/froyo_api.rb +4 -4
- data/lib/froyo_api/version.rb +1 -1
- data/spec/froyo_api/name_spec.rb +3 -5
- data/spec/froyo_api/password_spec.rb +0 -2
- data/spec/froyo_api/photo_spec.rb +0 -2
- metadata +29 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a819bbeb4acf1b74326b98494b769166bb82f7fc
|
4
|
+
data.tar.gz: 63043a605f865826836571bff64d761775dfa73c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 81e2f5cc2132c39bd70f847393f34db298a525f089f397f1b59b0111424ca9aa6a5239928addd6af1e02c9bfde1007b7e740d8dfc297d64a4cf3be15a04be966
|
7
|
+
data.tar.gz: 0ed92a6d03431c0674a4b7c77e72caae40f5345e963f2cd4e37ab149f10d9e771db54dbfbe7200c222fa22fbddbab835f26aba49845e719e3ef66e1e68b5bc4a
|
data/froyo_api.gemspec
CHANGED
@@ -20,4 +20,7 @@ Gem::Specification.new do |spec|
|
|
20
20
|
spec.add_development_dependency 'bundler', '~> 1.7'
|
21
21
|
spec.add_development_dependency 'rake', '~> 10.0'
|
22
22
|
spec.add_development_dependency 'rspec'
|
23
|
+
|
24
|
+
spec.add_runtime_dependency 'rest-client'
|
25
|
+
spec.add_runtime_dependency 'json'
|
23
26
|
end
|
data/lib/froyo_api.rb
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
require 'froyo_api/version'
|
2
|
-
require '
|
3
|
-
require '
|
4
|
-
require '
|
5
|
-
require '
|
2
|
+
require 'froyo_api/client'
|
3
|
+
require 'froyo_api/password'
|
4
|
+
require 'froyo_api/name'
|
5
|
+
require 'froyo_api/photo'
|
6
6
|
|
7
7
|
module FroyoApi
|
8
8
|
URL = 'http://api.froyo.io'
|
data/lib/froyo_api/version.rb
CHANGED
data/spec/froyo_api/name_spec.rb
CHANGED
@@ -2,10 +2,8 @@ require 'spec_helper'
|
|
2
2
|
|
3
3
|
RSpec.describe FroyoApi::Name do
|
4
4
|
let(:name) { FroyoApi::Name.new }
|
5
|
-
let(:client) { FroyoApi::Client.new }
|
6
5
|
|
7
6
|
before do
|
8
|
-
allow(client).to receive(:request)
|
9
7
|
allow(RestClient::Request).to receive(:execute).and_return({
|
10
8
|
'version' => '1.0',
|
11
9
|
'attributes' => {
|
@@ -29,10 +27,10 @@ RSpec.describe FroyoApi::Name do
|
|
29
27
|
it { expect(name.gender).to eq('m') }
|
30
28
|
end
|
31
29
|
|
32
|
-
context 'when initialized with "
|
33
|
-
let(:name) { FroyoApi::Name.new('
|
30
|
+
context 'when initialized with "f"' do
|
31
|
+
let(:name) { FroyoApi::Name.new('f') }
|
34
32
|
|
35
|
-
it { expect(name.gender).to eq('
|
33
|
+
it { expect(name.gender).to eq('f') }
|
36
34
|
end
|
37
35
|
end
|
38
36
|
|
@@ -2,10 +2,8 @@ require 'spec_helper'
|
|
2
2
|
|
3
3
|
RSpec.describe FroyoApi::Password do
|
4
4
|
let(:password) { FroyoApi::Password.new }
|
5
|
-
let(:client) { FroyoApi::Client.new }
|
6
5
|
|
7
6
|
before do
|
8
|
-
allow(client).to receive(:request)
|
9
7
|
allow(RestClient::Request).to receive(:execute).and_return({
|
10
8
|
"version" => "1.0",
|
11
9
|
"attributes" => {
|
@@ -2,10 +2,8 @@ require 'spec_helper'
|
|
2
2
|
|
3
3
|
RSpec.describe FroyoApi::Photo do
|
4
4
|
let(:photo) { FroyoApi::Photo.new }
|
5
|
-
let(:client) { FroyoApi::Client.new }
|
6
5
|
|
7
6
|
before do
|
8
|
-
allow(client).to receive(:request)
|
9
7
|
allow(RestClient::Request).to receive(:execute).and_return({
|
10
8
|
'version' => '1.0',
|
11
9
|
'attributes' => {
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: froyo_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Maciej Małecki
|
@@ -52,6 +52,34 @@ dependencies:
|
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rest-client
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: json
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
55
83
|
description: ''
|
56
84
|
email:
|
57
85
|
- smt116@gmail.com
|