random_data 1.2.0 → 1.2.1

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,4 +1,9 @@
1
- == 1.2.0 2007-09-17
1
+ == 1.2.1 2007-11-29
2
+
3
+ * 1 minor fix:
4
+ * Updated gem manifest
5
+
6
+ == 1.2.0 2007-11-29
2
7
 
3
8
  Thanks to Paul Barry and Hugh Sasse for some awesome patches!
4
9
 
data/Manifest.txt CHANGED
@@ -7,10 +7,12 @@ config/hoe.rb
7
7
  config/requirements.rb
8
8
  lib/random_data.rb
9
9
  lib/random_data/array_randomizer.rb
10
+ lib/random_data/booleans.rb
10
11
  lib/random_data/contact_info.rb
11
12
  lib/random_data/dates.rb
12
13
  lib/random_data/locations.rb
13
14
  lib/random_data/names.rb
15
+ lib/random_data/numbers.rb
14
16
  lib/random_data/text.rb
15
17
  lib/random_data/version.rb
16
18
  log/debug.log
@@ -0,0 +1,10 @@
1
+ module RandomData
2
+
3
+ module Booleans
4
+ #Returns true or false
5
+ def boolean
6
+ rand(2) == 1 ? true : false
7
+ end
8
+ end
9
+
10
+ end
@@ -0,0 +1,13 @@
1
+ module RandomData
2
+ module Numbers
3
+ #n can be an Integer or a Range. If it is an Integer, it just returns a random
4
+ #number greater than or equal to 0 and less than n. If it is a Range, it
5
+ #returns a random number within the range
6
+ # Examples
7
+ #
8
+ #
9
+ def number(n)
10
+ n.is_a?(Range) ? n.to_a.rand : rand(n)
11
+ end
12
+ end
13
+ end
@@ -2,7 +2,7 @@ module RandomData #:nodoc:
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 1
4
4
  MINOR = 2
5
- TINY = 0
5
+ TINY = 1
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: random_data
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ""
6
6
  authors:
7
7
  - Mike Subelsky
@@ -35,10 +35,12 @@ files:
35
35
  - config/requirements.rb
36
36
  - lib/random_data.rb
37
37
  - lib/random_data/array_randomizer.rb
38
+ - lib/random_data/booleans.rb
38
39
  - lib/random_data/contact_info.rb
39
40
  - lib/random_data/dates.rb
40
41
  - lib/random_data/locations.rb
41
42
  - lib/random_data/names.rb
43
+ - lib/random_data/numbers.rb
42
44
  - lib/random_data/text.rb
43
45
  - lib/random_data/version.rb
44
46
  - log/debug.log