acts_as_status_for 4.3.0 → 4.3.1

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: c4704bcb121d85980e42659a1142bd6c1d5c6146
4
- data.tar.gz: 7d513f57bdc1b79488fe2f81205205049167f9a0
3
+ metadata.gz: 55aa15db54ac712680db94e33beb3f5c5ca67263
4
+ data.tar.gz: 983746c94629e15d8d62e86062157ef92d6e0456
5
5
  SHA512:
6
- metadata.gz: 5a92c673905f7de849023cb01efa09db02b8d753bfd76490b65b846b917e72d10c37cd5c407561b58402905e424bab21b2172aec0fb97de412394e3b70e6844c
7
- data.tar.gz: 1095c8f2d6f5648896a4b64828372c9b28493c73daaa9f7f0cc2f32dc3c37181c214c8ce0e54e2877f6cad3fc2be64b00b47b06c95a6e9f7ba46ec01bc0b390d
6
+ metadata.gz: 9d15f6fdebfce40155824619cab1328f454dfe1ddbf522e232ad9803d5c6adde99f3d3e037635b17300ebc819be9faf1e1e6ac7ada018fd528ec841a0ed35f5c
7
+ data.tar.gz: 1cc76ad1caeff2fd0122e5f0e805ca5ada08a7d1869b22f8f423c2e1844087c58210677027c97ff9d665d3959c0c25ac2bb7a274f93311cd7d1d40dafe0235ff
data/VERSION CHANGED
@@ -1 +1 @@
1
- 4.3.0
1
+ 4.3.1
@@ -2,11 +2,11 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: acts_as_status_for 4.3.0 ruby lib
5
+ # stub: acts_as_status_for 4.3.1 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "acts_as_status_for".freeze
9
- s.version = "4.3.0"
9
+ s.version = "4.3.1"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib".freeze]
@@ -145,12 +145,12 @@ module ActsAsStatusFor
145
145
  if self.class.all_at_events.include?(event.to_sym)
146
146
  self.send("#{event}!") if self.respond_to?("#{event}!")
147
147
  else
148
- puts "Here"
149
148
  raise UnsupportedStatus.new("#{event} is not a status_at field")
150
149
  end
151
150
  end
152
151
  end
153
152
  end
153
+
154
154
  alias :current_status= :status=
155
155
  alias :statuses= :status=
156
156
 
@@ -163,6 +163,14 @@ describe ActsAsStatusFor do
163
163
  expect(subject.statuses).to eq('on_hold featured archived')
164
164
  end
165
165
 
166
+ it "setting to nil raises error" do
167
+ expect {
168
+ subject.status = nil
169
+ }.to raise_error(ActsAsStatusFor::UnsupportedStatus)
170
+ expect {
171
+ subject.statuses = nil
172
+ }.to raise_error(ActsAsStatusFor::UnsupportedStatus)
173
+ end
166
174
  it "setting it to blank clears all states when clear_status is true" do
167
175
  subject.on_hold!
168
176
  subject.archived!
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: acts_as_status_for
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.0
4
+ version: 4.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Curtis Schofield