polleverywhere 0.0.18 → 0.0.19

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: 6e4afe38059ccdf6bdc400ea88bf3175400f8086
4
- data.tar.gz: 0bf3812ae15e43d9e7c6e6f173e36f5a85f84bba
3
+ metadata.gz: 55593871c1e7e8215d2e8c31e9d113dee87f36c1
4
+ data.tar.gz: e37beb50242387f5d7e1d8a42bb35a98df5a2c65
5
5
  SHA512:
6
- metadata.gz: e67e60bd7f3a8e7414e90612d3878fcb147719339af90f9a8bbee784c5889d6086790d919d08e49572c3f6381bae1761eac7b30b0df4759051265ff600052627
7
- data.tar.gz: 6e35be4fd064faeb8aa7197c2615ff29c5eb7b8205bd2156cd2fbcc8f91944e587762a852c635648e99b4a17a85c6e012cf347cdaf81f16b403b799ced4fb61d
6
+ metadata.gz: 1c8e895dd2677dd7685d11581f582c1ac6e2565955418b133dc325e2aa662ebafa78112076d49b362b7fe0522fcfc5aa00d991a9f6e0c66ea9ce2c042a78a66c
7
+ data.tar.gz: a5d766893b732343041719e530a964ce0ca1b415056aa71c866f47c00eecd33ef9886a8fb93a35edf64eafb3a9e0b197f9ba0f2b470e71f1713a9ffb46e41954
@@ -1,8 +1,6 @@
1
1
  language: ruby
2
2
 
3
3
  rvm:
4
- - ree
5
- - 1.8.7
6
4
  - 1.9.3
7
5
  - 2.0.0
8
6
  - 2.1.3
@@ -172,7 +172,7 @@ module PollEverywhere # :nodoc
172
172
 
173
173
  def archive
174
174
  if persisted?
175
- http.delete.to(path + "/results/archive").response do |response|
175
+ http.delete.from(path + "/results/archive").response do |response|
176
176
  return true
177
177
  end
178
178
 
@@ -184,7 +184,7 @@ module PollEverywhere # :nodoc
184
184
 
185
185
  def clear
186
186
  if persisted?
187
- http.delete.to(path + "/results").response do |response|
187
+ http.delete.from(path + "/results").response do |response|
188
188
  return true
189
189
  end
190
190
 
@@ -195,7 +195,7 @@ module PollEverywhere # :nodoc
195
195
  end
196
196
 
197
197
  def destroy
198
- http.delete(path).response do |response|
198
+ http.delete.from(path).response do |response|
199
199
  self.id = self.permalink = nil
200
200
  end
201
201
  end
@@ -291,4 +291,4 @@ module PollEverywhere # :nodoc
291
291
  end
292
292
  end
293
293
  end
294
- end
294
+ end
@@ -1,3 +1,3 @@
1
1
  module PollEverywhere
2
- VERSION = "0.0.18"
2
+ VERSION = "0.0.19"
3
3
  end
@@ -7,12 +7,15 @@ describe "API", :type => :request do
7
7
  end
8
8
 
9
9
  context "multiple choice" do
10
- before(:all) do
10
+ before do
11
11
  @mcp = PollEverywhere::MultipleChoicePoll.from_hash(:title => 'Hey dude!', :options => %w[red blue green])
12
12
  end
13
+ after do
14
+ @mcp.destroy if @mcp.id
15
+ end
13
16
 
14
17
  context "creation" do
15
- before(:all) do
18
+ before do
16
19
  @mcp.save
17
20
  end
18
21
 
@@ -41,13 +44,14 @@ describe "API", :type => :request do
41
44
 
42
45
  context "get" do
43
46
  it "should get poll" do
47
+ @mcp.save
44
48
  @gotten_mcp = PollEverywhere::MultipleChoicePoll.get(@mcp.permalink)
45
49
  expect(@gotten_mcp.title).to eql(@mcp.title)
46
50
  end
47
51
  end
48
52
 
49
53
  context "updates" do
50
- before(:all) do
54
+ before do
51
55
  @mcp.title = "My pita bread is moldy"
52
56
  @mcp.options.first.value = "MOLD SUCKS!"
53
57
  @mcp.save
@@ -97,12 +101,15 @@ describe "API", :type => :request do
97
101
  end
98
102
 
99
103
  context "free text" do
100
- before(:all) do
104
+ before do
101
105
  @ftp = PollEverywhere::FreeTextPoll.from_hash(:title => 'Got feedback?')
102
106
  end
107
+ after do
108
+ @ftp.destroy if @ftp.id
109
+ end
103
110
 
104
111
  context "creation" do
105
- before(:all) do
112
+ before do
106
113
  @ftp.save
107
114
  end
108
115
 
@@ -117,13 +124,14 @@ describe "API", :type => :request do
117
124
 
118
125
  context "get" do
119
126
  it "should get poll" do
127
+ @ftp.save
120
128
  @gotten_ftp = PollEverywhere::FreeTextPoll.get(@ftp.permalink)
121
129
  expect(@gotten_ftp.title).to eql(@ftp.title)
122
130
  end
123
131
  end
124
132
 
125
133
  context "updates" do
126
- before(:all) do
134
+ before do
127
135
  @ftp.title = "My pita bread is moldy"
128
136
  @ftp.save
129
137
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: polleverywhere
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.18
4
+ version: 0.0.19
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brad Gessler, Steel Fu
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-11-06 00:00:00.000000000 Z
11
+ date: 2015-01-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json