raystest 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -0
- data/VERSION +1 -1
- data/nbproject/private/private.properties +2 -0
- data/nbproject/private/rake-d.txt +0 -0
- data/nbproject/project.properties +7 -0
- data/nbproject/project.xml +15 -0
- data/raystest.gemspec +11 -2
- data/test/main.rb +23 -0
- data/test/test_raystest.rb +23 -1
- metadata +24 -4
data/Rakefile
CHANGED
@@ -11,6 +11,7 @@ begin
|
|
11
11
|
gem.homepage = "http://github.com/raygao/raystest"
|
12
12
|
gem.authors = ["Raymond Gao"]
|
13
13
|
gem.add_development_dependency "thoughtbot-shoulda", ">= 0"
|
14
|
+
gem.add_development_dependency 'progressbar', '>=0'
|
14
15
|
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
|
15
16
|
end
|
16
17
|
Jeweler::GemcutterTasks.new
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.2
|
File without changes
|
@@ -0,0 +1,15 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<project xmlns="http://www.netbeans.org/ns/project/1">
|
3
|
+
<type>org.netbeans.modules.ruby.rubyproject</type>
|
4
|
+
<configuration>
|
5
|
+
<data xmlns="http://www.netbeans.org/ns/ruby-project/1">
|
6
|
+
<name>raystest</name>
|
7
|
+
<source-roots>
|
8
|
+
<root id="src.dir"/>
|
9
|
+
</source-roots>
|
10
|
+
<test-roots>
|
11
|
+
<root id="test.src.dir"/>
|
12
|
+
</test-roots>
|
13
|
+
</data>
|
14
|
+
</configuration>
|
15
|
+
</project>
|
data/raystest.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{raystest}
|
8
|
-
s.version = "1.0.
|
8
|
+
s.version = "1.0.2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Raymond Gao"]
|
12
|
-
s.date = %q{2010-11-
|
12
|
+
s.date = %q{2010-11-07}
|
13
13
|
s.description = %q{Raystest: This is RayGao's 1st test gem on RubyGems.org, now github is no longer supported as a GEM server.}
|
14
14
|
s.email = %q{raygao2000@yahoo.com}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -24,8 +24,13 @@ Gem::Specification.new do |s|
|
|
24
24
|
"Rakefile",
|
25
25
|
"VERSION",
|
26
26
|
"lib/raystest.rb",
|
27
|
+
"nbproject/private/private.properties",
|
28
|
+
"nbproject/private/rake-d.txt",
|
29
|
+
"nbproject/project.properties",
|
30
|
+
"nbproject/project.xml",
|
27
31
|
"raystest.gemspec",
|
28
32
|
"test/helper.rb",
|
33
|
+
"test/main.rb",
|
29
34
|
"test/test_raystest.rb"
|
30
35
|
]
|
31
36
|
s.homepage = %q{http://github.com/raygao/raystest}
|
@@ -35,6 +40,7 @@ Gem::Specification.new do |s|
|
|
35
40
|
s.summary = %q{Raystest: This is RayGao's 1st test gem on RubyGems.org}
|
36
41
|
s.test_files = [
|
37
42
|
"test/helper.rb",
|
43
|
+
"test/main.rb",
|
38
44
|
"test/test_raystest.rb"
|
39
45
|
]
|
40
46
|
|
@@ -44,11 +50,14 @@ Gem::Specification.new do |s|
|
|
44
50
|
|
45
51
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
46
52
|
s.add_development_dependency(%q<thoughtbot-shoulda>, [">= 0"])
|
53
|
+
s.add_development_dependency(%q<progressbar>, [">= 0"])
|
47
54
|
else
|
48
55
|
s.add_dependency(%q<thoughtbot-shoulda>, [">= 0"])
|
56
|
+
s.add_dependency(%q<progressbar>, [">= 0"])
|
49
57
|
end
|
50
58
|
else
|
51
59
|
s.add_dependency(%q<thoughtbot-shoulda>, [">= 0"])
|
60
|
+
s.add_dependency(%q<progressbar>, [">= 0"])
|
52
61
|
end
|
53
62
|
end
|
54
63
|
|
data/test/main.rb
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
# To change this template, choose Tools | Templates
|
2
|
+
# and open the template in the editor.
|
3
|
+
|
4
|
+
puts "Hello World"
|
5
|
+
|
6
|
+
require 'rubygems'
|
7
|
+
|
8
|
+
require 'progressbar'
|
9
|
+
require 'raystest'
|
10
|
+
|
11
|
+
rs = Raystest::RaysClass.new
|
12
|
+
|
13
|
+
rs.do_print_stars
|
14
|
+
|
15
|
+
bar = ProgressBar.new("Example progress", 50)
|
16
|
+
total = 0
|
17
|
+
until total >= 50
|
18
|
+
sleep(rand(2)/2.0)
|
19
|
+
increment = (rand(6) + 3)
|
20
|
+
bar.inc(increment)
|
21
|
+
total += increment
|
22
|
+
end
|
23
|
+
puts '---done---'
|
data/test/test_raystest.rb
CHANGED
@@ -1,4 +1,6 @@
|
|
1
|
-
require '
|
1
|
+
require 'test/unit'
|
2
|
+
require 'progressbar' #loading 'progressbar' gem
|
3
|
+
require 'raystest' #loading 'raystest' gem
|
2
4
|
|
3
5
|
class TestRaystest < Test::Unit::TestCase
|
4
6
|
|
@@ -7,4 +9,24 @@ class TestRaystest < Test::Unit::TestCase
|
|
7
9
|
assert rs.do_print_stars
|
8
10
|
end
|
9
11
|
|
12
|
+
def test_raystest_gem
|
13
|
+
rs = Raystest::RaysClass.new
|
14
|
+
|
15
|
+
rs.do_print_stars
|
16
|
+
bar = ProgressBar.new("Example progress", 25)
|
17
|
+
total = 0
|
18
|
+
until total >= 25
|
19
|
+
sleep(rand(2)/2.0)
|
20
|
+
increment = (rand(6) + 3)
|
21
|
+
bar.inc(increment)
|
22
|
+
total += increment
|
23
|
+
end
|
24
|
+
puts '---done---'
|
25
|
+
|
26
|
+
assert rs
|
27
|
+
end
|
28
|
+
|
10
29
|
end
|
30
|
+
|
31
|
+
|
32
|
+
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: raystest
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 19
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 1
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 1.0.
|
9
|
+
- 2
|
10
|
+
version: 1.0.2
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Raymond Gao
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-11-
|
18
|
+
date: 2010-11-07 00:00:00 +01:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -32,6 +32,20 @@ dependencies:
|
|
32
32
|
version: "0"
|
33
33
|
type: :development
|
34
34
|
version_requirements: *id001
|
35
|
+
- !ruby/object:Gem::Dependency
|
36
|
+
name: progressbar
|
37
|
+
prerelease: false
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ">="
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
hash: 3
|
44
|
+
segments:
|
45
|
+
- 0
|
46
|
+
version: "0"
|
47
|
+
type: :development
|
48
|
+
version_requirements: *id002
|
35
49
|
description: "Raystest: This is RayGao's 1st test gem on RubyGems.org, now github is no longer supported as a GEM server."
|
36
50
|
email: raygao2000@yahoo.com
|
37
51
|
executables: []
|
@@ -49,8 +63,13 @@ files:
|
|
49
63
|
- Rakefile
|
50
64
|
- VERSION
|
51
65
|
- lib/raystest.rb
|
66
|
+
- nbproject/private/private.properties
|
67
|
+
- nbproject/private/rake-d.txt
|
68
|
+
- nbproject/project.properties
|
69
|
+
- nbproject/project.xml
|
52
70
|
- raystest.gemspec
|
53
71
|
- test/helper.rb
|
72
|
+
- test/main.rb
|
54
73
|
- test/test_raystest.rb
|
55
74
|
has_rdoc: true
|
56
75
|
homepage: http://github.com/raygao/raystest
|
@@ -88,4 +107,5 @@ specification_version: 3
|
|
88
107
|
summary: "Raystest: This is RayGao's 1st test gem on RubyGems.org"
|
89
108
|
test_files:
|
90
109
|
- test/helper.rb
|
110
|
+
- test/main.rb
|
91
111
|
- test/test_raystest.rb
|