zeke-monkey_patches 0.1.18 → 0.1.19

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.
data/VERSION.yml CHANGED
@@ -1,4 +1,4 @@
1
1
  ---
2
2
  :minor: 1
3
- :patch: 18
3
+ :patch: 19
4
4
  :major: 0
@@ -152,6 +152,12 @@ class String
152
152
  def upcase?
153
153
  self.upcase == self
154
154
  end
155
+
156
+ # Returns true if all letters in the string are lowercase
157
+ def downcase?
158
+ self.downcase == self
159
+ end
160
+
155
161
 
156
162
  def replace_wonky_characters_with_ascii
157
163
  t = self.to_s
@@ -95,11 +95,17 @@ describe "MonkeyPatches" do
95
95
  " this \t is also a test ".remove_whitespace.should == "this is also a test"
96
96
  end
97
97
 
98
- it "determines capitalization" do
98
+ it "determines whether string is capitalized" do
99
99
  "This is mixed case".upcase?.should == false
100
100
  "ALL CAPS DUDE".upcase?.should == true
101
101
  "ALL-CAPS, WITH! EXTRA.. CHARS & STUFF/SYMBOLS?".upcase?.should == true
102
102
  end
103
+
104
+ it "determines whether string is lowercase" do
105
+ "This is mixed case".downcase?.should == false
106
+ "all lowers dude".downcase?.should == true
107
+ "all-caps, with! extra.. chars & stuff/symbols?".downcase?.should == true
108
+ end
103
109
 
104
110
  # Array specs
105
111
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zeke-monkey_patches
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.18
4
+ version: 0.1.19
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zeke Sikelianos