turn 0.9.6 → 0.9.7
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/CONTRIBUTING.md +40 -0
- data/History.txt +6 -0
- data/Index.rb +34 -0
- data/LICENSE.txt +20 -34
- data/NOTICE.md +12 -0
- data/README.md +31 -13
- data/Version.txt +1 -1
- data/lib/turn/colorize.rb +2 -2
- data/lib/turn/command.rb +20 -8
- data/lib/turn/configuration.rb +61 -29
- data/lib/turn/decorators/topten_decorator.rb +67 -0
- data/lib/turn/minitest.rb +3 -4
- data/lib/turn/reporter.rb +1 -1
- data/lib/turn/runners/isorunner.rb +1 -1
- data/lib/turn/runners/minirunner.rb +10 -2
- data/lib/turn/version.rb +1 -1
- data/test/helper.rb +18 -0
- data/test/test_runners.rb +27 -0
- metadata +52 -14
- data/LICENSE-GPL2.txt +0 -340
- data/LICENSE-MIT.txt +0 -21
- data/LICENSE-RUBY.txt +0 -56
data/CONTRIBUTING.md
ADDED
@@ -0,0 +1,40 @@
|
|
1
|
+
# CONTRIBUTING
|
2
|
+
|
3
|
+
1. Fork it
|
4
|
+
2. Create your feature branch (`git checkout -b my_new_feature`)
|
5
|
+
3. Commit your changes (`git commit -am 'Added some feature'`)
|
6
|
+
4. Push to the branch (`git push origin my_new_feature`)
|
7
|
+
5. Create a new Pull Request
|
8
|
+
|
9
|
+
If you are a project member please follow the same process (minus the forking). For significant changes please wait for another developer to review and merge them, whereas small contributions/fixes can be merged without review. The recommended naming scheme for feature branches is 'feature\_name\_$1\_`date +"%Y%m%d"`'.
|
10
|
+
|
11
|
+
You may want to look into the [grb](http://github.com/jinzhu/grb) gem for easier handling of remote branches.
|
12
|
+
|
13
|
+
|
14
|
+
## Building
|
15
|
+
|
16
|
+
NOTE: The process described here will change sooner than later.
|
17
|
+
|
18
|
+
Turn uses the Indexer and Mast gems to simplify project building.
|
19
|
+
|
20
|
+
The Indexer gem defines a strict structure for project metadata. Use the `index`
|
21
|
+
command to build the `.index` file from the editable `Index.rb` source.
|
22
|
+
The `.gemspec` file is written to get the information it needs from the `.index`
|
23
|
+
file. To build a gem simply use `gem build .gemspec`.
|
24
|
+
|
25
|
+
The `mast` command is used to keep an up-to-date `Manifest.txt` file. The gemspec
|
26
|
+
uses this file to determine which files to include in the gem. Just use
|
27
|
+
`mast -u` to update it. The top line in the Manifest.txt file determines it's
|
28
|
+
contents.
|
29
|
+
|
30
|
+
|
31
|
+
## Solo and Cross Runners
|
32
|
+
|
33
|
+
An important aspect of Turn's design that needs be kept in mind, is the way
|
34
|
+
_solo_ and _cross_ testing features are implemented. This is some really
|
35
|
+
neat code actually (IMO), but it might be difficult to grasp with out some
|
36
|
+
explanation. What turn does when using the `--solo` or `--cross` options,
|
37
|
+
is <i>shell out to itself</i> using the YAML reporter. It does this repeatedly
|
38
|
+
for each test, or each pair of tests, respectively, and then collates all the
|
39
|
+
resulting YAML reports into a single report, which it then feeds back into the
|
40
|
+
selected reporter.
|
data/History.txt
CHANGED
@@ -1,3 +1,9 @@
|
|
1
|
+
=== 0.9.7 / 2014-03-14
|
2
|
+
* Fix -n option for running named tests (#78)
|
3
|
+
* Change default output mode to 'pretty'
|
4
|
+
* Add option to print top 10 longest running tests
|
5
|
+
* Fix home directory lookup
|
6
|
+
|
1
7
|
=== 0.9.6 / 2012-06-26
|
2
8
|
* Override output() instead of changeing @@out. (#96,#97)
|
3
9
|
* Update install instructions in README. (#95)
|
data/Index.rb
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require File.dirname(__FILE__) + '/lib/turn/version'
|
4
|
+
|
5
|
+
version Turn::VERSION #File.read('Version.txt').strip
|
6
|
+
|
7
|
+
name 'turn'
|
8
|
+
title 'Turn'
|
9
|
+
summary 'Test Reporters (New) -- new output formats for Testing'
|
10
|
+
|
11
|
+
description "Turn provides a set of alternative runners for MiniTest, both colorful and informative."
|
12
|
+
|
13
|
+
authors [
|
14
|
+
'Thomas Sawyer <transfire@gmail.com>',
|
15
|
+
'Tim Pease <tim.pease@gmail.com>'
|
16
|
+
]
|
17
|
+
|
18
|
+
requirements [
|
19
|
+
'ansi',
|
20
|
+
'minitest 4~',
|
21
|
+
'rake (build)',
|
22
|
+
'indexer (build)',
|
23
|
+
'mast (build)'
|
24
|
+
]
|
25
|
+
|
26
|
+
resources(
|
27
|
+
'home' => 'http://rubygems.org/gems/turn',
|
28
|
+
'code' => 'http://github.com/TwP/turn'
|
29
|
+
)
|
30
|
+
|
31
|
+
copyrights [
|
32
|
+
'2006 Tim Pease (MIT)',
|
33
|
+
'2009 Thomas Sawyer (MIT)'
|
34
|
+
]
|
data/LICENSE.txt
CHANGED
@@ -1,35 +1,21 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
== TestUnit
|
24
|
-
|
25
|
-
Copyright:: (c) Nathaniel Talbott
|
26
|
-
License:: The Ruby License
|
27
|
-
|
28
|
-
This software is distributed under the same terms as Ruby.
|
29
|
-
|
30
|
-
See license/RUBY-LICENSE.txt for detiails.
|
31
|
-
|
32
|
-
Turn tightly couples with TesUnit which means in some cases
|
33
|
-
TestUnit code might be reused and modified so Turn will
|
34
|
-
interface with TestUnit effectively.
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
'Software'), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
17
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
18
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
19
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
20
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
35
21
|
|
data/NOTICE.md
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
# Copyright Notices
|
2
|
+
|
3
|
+
## MiniTest
|
4
|
+
|
5
|
+
Copyright (c) Ryan Davis, Seattle.rb
|
6
|
+
|
7
|
+
MIT License
|
8
|
+
|
9
|
+
Turn tightly couples with MiniTest which means in some cases
|
10
|
+
MiniTest code might be reused and modified so Turn will
|
11
|
+
interface with MiniTest effectively.
|
12
|
+
|
data/README.md
CHANGED
@@ -1,9 +1,8 @@
|
|
1
|
-
# TURN - MiniTest Reporters
|
1
|
+
# TURN - MiniTest Reporters [](https://travis-ci.org/turn-project/turn)
|
2
2
|
by Tim Pease
|
3
|
-
http://
|
3
|
+
http://rubygems.org/gems/turn
|
4
4
|
|
5
|
-
|
6
|
-
## DESCRIPTION:
|
5
|
+
## DESCRIPTION
|
7
6
|
|
8
7
|
TURN is a new way to view test results. With longer running tests, it
|
9
8
|
can be very frustrating to see a failure (....F...) and then have to wait till
|
@@ -15,10 +14,8 @@ If you have the 'ansi' gem installed, then TURN output will be displayed in
|
|
15
14
|
wonderful technicolor (but only if your terminal supports ANSI color codes).
|
16
15
|
Well, the only colors are green and red, but that is still color.
|
17
16
|
|
18
|
-
<b>Interested in improving Turn?</b> [Please read this](https://github.com/TwP/turn/wiki/Implementation).
|
19
|
-
|
20
17
|
|
21
|
-
## FEATURES
|
18
|
+
## FEATURES
|
22
19
|
|
23
20
|
General usage provides better test output. Here is some sample output:
|
24
21
|
|
@@ -44,9 +41,9 @@ General usage provides better test output. Here is some sample output:
|
|
44
41
|
Turn also provides solo and cross test modes when run from the *turn* commandline
|
45
42
|
application.
|
46
43
|
|
47
|
-
## INSTRUCTION
|
44
|
+
## INSTRUCTION
|
48
45
|
|
49
|
-
Turn can be
|
46
|
+
Turn can be used from the command-line or via require. The command-line tool
|
50
47
|
offers additional options for how one runs tests.
|
51
48
|
|
52
49
|
### Command Line
|
@@ -119,24 +116,45 @@ Also, you can use following environment variables to adjust settings:
|
|
119
116
|
backtrace Number of backtrace lines to display. Default: set from ENV or nil
|
120
117
|
ansi Force colorize output (requires 'ansi' gem).
|
121
118
|
|
119
|
+
Finally, you can include your own custom Reporter type (aka format). Turn will search for reporters in the `.turn/reporters/`
|
120
|
+
directory of your local project and then in your user home directory. So for example, if you specified the following:
|
121
|
+
|
122
|
+
Turn.config.format = :cool
|
123
|
+
|
124
|
+
Then Turn will look first for `./.turn/reporters/cool_reporter.rb`, then `~/.turn/reporters/cool_reporter.rb`.
|
125
|
+
|
126
|
+
See source code for examples of how to write your own reporters.
|
122
127
|
|
123
|
-
|
128
|
+
|
129
|
+
## REQUIREMENTS
|
124
130
|
|
125
131
|
* ansi 1.1+ (for colorized output and progress bar output mode)
|
126
132
|
|
127
133
|
|
128
|
-
## INSTALLATION
|
134
|
+
## INSTALLATION
|
129
135
|
|
130
136
|
Follow the ususal procedure:
|
131
137
|
|
132
138
|
$ gem install turn
|
133
139
|
|
134
140
|
|
135
|
-
##
|
141
|
+
## TODO
|
142
|
+
|
143
|
+
* Setup CI for Ruby 1.9 and 2.0
|
144
|
+
* Support MiniTest v5.0
|
145
|
+
* Remove indexer and mast gems from build process
|
146
|
+
* Remove support for Ruby versions < 1.9
|
147
|
+
* Remove support for Test::Unit
|
148
|
+
* General code cleanup
|
149
|
+
|
150
|
+
|
151
|
+
## LICENSE
|
136
152
|
|
137
153
|
MIT License
|
138
154
|
|
139
|
-
Copyright (c) 2006
|
155
|
+
Copyright (c) 2006 Tim Pease
|
156
|
+
Copyright (c) 2009 Thomas Sawyer
|
157
|
+
Copyright (c) 2013 Michael Kohl, Daniel Yoon
|
140
158
|
|
141
159
|
Permission is hereby granted, free of charge, to any person obtaining
|
142
160
|
a copy of this software and associated documentation files (the
|
data/Version.txt
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.9.
|
1
|
+
0.9.7
|
data/lib/turn/colorize.rb
CHANGED
data/lib/turn/command.rb
CHANGED
@@ -24,10 +24,10 @@ module Turn
|
|
24
24
|
# --cross run each pair of test files in a separate process
|
25
25
|
#
|
26
26
|
# OUTPUT MODES
|
27
|
-
# -O, --outline turn's original case/test outline mode
|
27
|
+
# -O, --outline turn's original case/test outline mode
|
28
28
|
# -P, --progress indicates progress with progress bar
|
29
|
-
# -D, --dotted
|
30
|
-
# -R, -T, --pretty new pretty output mode
|
29
|
+
# -D, --dot, --dotted test-unit's traditonal dot-progress mode
|
30
|
+
# -R, -T, --pretty new pretty output mode [default]
|
31
31
|
# -C, --cue cue for action on each failure/error
|
32
32
|
# -M, --marshal dump output as YAML (normal run mode only)
|
33
33
|
#
|
@@ -70,6 +70,9 @@ module Turn
|
|
70
70
|
# Output mode.
|
71
71
|
attr :outmode
|
72
72
|
|
73
|
+
# Decorator mode.
|
74
|
+
attr :decmode
|
75
|
+
|
73
76
|
# Enable full backtrace
|
74
77
|
attr :trace
|
75
78
|
|
@@ -95,6 +98,7 @@ module Turn
|
|
95
98
|
@requires = []
|
96
99
|
@runmode = nil
|
97
100
|
@outmode = nil
|
101
|
+
@decmode = nil
|
98
102
|
@trace = nil
|
99
103
|
@natural = false
|
100
104
|
@verbose = false
|
@@ -193,7 +197,7 @@ module Turn
|
|
193
197
|
opts.separator " "
|
194
198
|
opts.separator "OUTPUT MODES"
|
195
199
|
|
196
|
-
opts.on('--outline', '-O', "turn's original case/test outline mode
|
200
|
+
opts.on('--outline', '-O', "turn's original case/test outline mode") do
|
197
201
|
@outmode = :outline
|
198
202
|
end
|
199
203
|
|
@@ -201,11 +205,11 @@ module Turn
|
|
201
205
|
@outmode = :progress
|
202
206
|
end
|
203
207
|
|
204
|
-
opts.on('--dotted', '-D', "test-unit's traditonal dot-progress mode") do
|
205
|
-
@outmode = :
|
208
|
+
opts.on('--dot', '--dotted', '-D', "test-unit's traditonal dot-progress mode") do
|
209
|
+
@outmode = :dot
|
206
210
|
end
|
207
211
|
|
208
|
-
opts.on('--pretty', '-R', '-T', "new pretty output mode") do
|
212
|
+
opts.on('--pretty', '-R', '-T', "new pretty output mode [default]") do
|
209
213
|
@outmode = :pretty
|
210
214
|
end
|
211
215
|
|
@@ -218,11 +222,18 @@ module Turn
|
|
218
222
|
@outmode = :marshal
|
219
223
|
end
|
220
224
|
|
225
|
+
opts.separator " "
|
226
|
+
opts.separator "DECORATOR MODES"
|
227
|
+
|
228
|
+
opts.on('--topten', "show only top ten slowest tests") do
|
229
|
+
@decmode = :topten
|
230
|
+
end
|
231
|
+
|
221
232
|
opts.separator " "
|
222
233
|
opts.separator "COMMAND OPTIONS"
|
223
234
|
|
224
235
|
opts.on('--debug', "turn debug mode on") do
|
225
|
-
$DEBUG
|
236
|
+
$DEBUG = true
|
226
237
|
end
|
227
238
|
|
228
239
|
opts.on('--warn', "turn warnings on") do
|
@@ -258,6 +269,7 @@ module Turn
|
|
258
269
|
c.tests = tests
|
259
270
|
c.runmode = runmode
|
260
271
|
c.format = outmode
|
272
|
+
c.mode = decmode
|
261
273
|
c.pattern = pattern
|
262
274
|
c.matchcase = matchcase
|
263
275
|
c.trace = trace
|
data/lib/turn/configuration.rb
CHANGED
@@ -36,7 +36,11 @@ module Turn
|
|
36
36
|
# Reporter type.
|
37
37
|
attr_accessor :format
|
38
38
|
|
39
|
-
#
|
39
|
+
# Report modifier. These act as decorators on the reporter class.
|
40
|
+
attr_accessor :mode
|
41
|
+
|
42
|
+
# Run mode, which defaults to `nil`, but can also be `:solo`,
|
43
|
+
# `:cross` or `:marshal`.
|
40
44
|
attr_accessor :runmode
|
41
45
|
|
42
46
|
# Test against live install (i.e. Don't use loadpath option)
|
@@ -52,7 +56,7 @@ module Turn
|
|
52
56
|
attr_accessor :mark
|
53
57
|
|
54
58
|
# Test framework, either `:minitest` or `:testunit`.
|
55
|
-
#
|
59
|
+
# TODO: Is this used any more?
|
56
60
|
attr_accessor :framework
|
57
61
|
|
58
62
|
# Enable full backtrace
|
@@ -66,20 +70,24 @@ module Turn
|
|
66
70
|
@verbose
|
67
71
|
end
|
68
72
|
|
73
|
+
#
|
69
74
|
def live?
|
70
75
|
@live
|
71
76
|
end
|
72
77
|
|
78
|
+
#
|
73
79
|
def natural?
|
74
80
|
@natural
|
75
81
|
end
|
76
82
|
|
83
|
+
#
|
77
84
|
def ansi?
|
78
85
|
@ansi
|
79
86
|
end
|
80
87
|
|
81
88
|
private
|
82
89
|
|
90
|
+
#
|
83
91
|
def initialize
|
84
92
|
yield(self) if block_given?
|
85
93
|
initialize_defaults
|
@@ -99,6 +107,7 @@ module Turn
|
|
99
107
|
@natural ||= false
|
100
108
|
@verbose ||= false
|
101
109
|
@format ||= environment_format
|
110
|
+
@mode ||= environment_mode
|
102
111
|
@trace ||= environment_trace
|
103
112
|
@ansi ||= environment_ansi
|
104
113
|
|
@@ -177,34 +186,52 @@ module Turn
|
|
177
186
|
files.map{ |path| File.dirname(path).sub(Dir.pwd+'/','') }.uniq.join(',')
|
178
187
|
end
|
179
188
|
|
180
|
-
#
|
189
|
+
# Get selected reporter with any mode decorator.
|
181
190
|
def reporter
|
182
|
-
@reporter ||= (
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
191
|
+
@reporter ||= decorate_reporter(reporter_class.new($stdout, reporter_options))
|
192
|
+
end
|
193
|
+
|
194
|
+
# Load reporter based on output mode and return its class.
|
195
|
+
def reporter_class
|
196
|
+
rpt_format = format || :pretty
|
197
|
+
class_name = rpt_format.to_s.capitalize + "Reporter"
|
198
|
+
|
199
|
+
path = "turn/reporters/#{rpt_format}_reporter"
|
200
|
+
|
201
|
+
[File.expand_path('~'), Dir.pwd].each do |dir|
|
202
|
+
file = File.join(dir, ".turn", "reporters", "#{rpt_format}_reporter.rb")
|
203
|
+
path = file if File.exist?(file)
|
204
|
+
end
|
205
|
+
|
206
|
+
require path
|
207
|
+
|
208
|
+
Turn.const_get(class_name)
|
209
|
+
end
|
210
|
+
|
211
|
+
#
|
212
|
+
def decorate_reporter(reporter)
|
213
|
+
if mode
|
214
|
+
decorator_class.new(reporter)
|
215
|
+
else
|
216
|
+
reporter
|
217
|
+
end
|
218
|
+
end
|
219
|
+
|
220
|
+
#
|
221
|
+
def decorator_class
|
222
|
+
return nil unless mode
|
223
|
+
|
224
|
+
class_name = mode.to_s.capitalize + "Decorator"
|
225
|
+
|
226
|
+
path = "turn/decorators/#{mode}_decorator"
|
227
|
+
[File.expand_path('~'), Dir.pwd].each do |dir|
|
228
|
+
file = File.join(dir, ".turn", "decorators", "#{mode}_reporter.rb")
|
229
|
+
path = file if File.exist?(file)
|
230
|
+
end
|
231
|
+
|
232
|
+
require path
|
233
|
+
|
234
|
+
Turn.const_get(class_name)
|
208
235
|
end
|
209
236
|
|
210
237
|
#
|
@@ -217,6 +244,11 @@ module Turn
|
|
217
244
|
ENV['rpt']
|
218
245
|
end
|
219
246
|
|
247
|
+
#
|
248
|
+
def environment_mode
|
249
|
+
ENV['mode']
|
250
|
+
end
|
251
|
+
|
220
252
|
#
|
221
253
|
def environment_trace
|
222
254
|
(ENV['backtrace'] ? ENV['backtrace'].to_i : nil)
|
@@ -0,0 +1,67 @@
|
|
1
|
+
module Turn
|
2
|
+
|
3
|
+
class ToptenDecorator
|
4
|
+
|
5
|
+
def initialize(reporter)
|
6
|
+
@reporter = reporter
|
7
|
+
end
|
8
|
+
|
9
|
+
def method_missing(m,*args,&block)
|
10
|
+
@reporter.send(m,*args,&block)
|
11
|
+
end
|
12
|
+
|
13
|
+
def start_case(kase)
|
14
|
+
@reporter.start_case(kase)
|
15
|
+
@top_ten_current_case = kase
|
16
|
+
end
|
17
|
+
|
18
|
+
def start_test(test)
|
19
|
+
@reporter.start_test(test)
|
20
|
+
test_time_data[test_key(test)] = {:start => Time.now}
|
21
|
+
end
|
22
|
+
|
23
|
+
def finish_test(test)
|
24
|
+
@reporter.finish_test(test)
|
25
|
+
test_time_data[test_key(test)][:end] = Time.now
|
26
|
+
end
|
27
|
+
|
28
|
+
def finish_suite(suite)
|
29
|
+
@reporter.finish_suite(suite)
|
30
|
+
io.puts
|
31
|
+
io.puts Colorize.bold("Top 10 Longest Running Tests")
|
32
|
+
top_ten_times.each do |(test_name, time)|
|
33
|
+
io.print format_time(time)
|
34
|
+
io.puts format_test_name(test_name, time)
|
35
|
+
end
|
36
|
+
io.puts
|
37
|
+
end
|
38
|
+
|
39
|
+
private
|
40
|
+
|
41
|
+
def test_key(test)
|
42
|
+
"#{@top_ten_current_case.name} #{test}"
|
43
|
+
end
|
44
|
+
|
45
|
+
def top_ten_times
|
46
|
+
test_times.sort_by {|(_, time)| -time}.take(10)
|
47
|
+
end
|
48
|
+
|
49
|
+
def test_times
|
50
|
+
test_time_data.map {|(test, times)| [test, times[:end] - times[:start]]}
|
51
|
+
end
|
52
|
+
|
53
|
+
def test_time_data
|
54
|
+
@test_time_data ||= {}
|
55
|
+
end
|
56
|
+
|
57
|
+
def format_time(time)
|
58
|
+
Colorize.blue(time)
|
59
|
+
end
|
60
|
+
|
61
|
+
def format_test_name(test_name, time)
|
62
|
+
test_name.tabto(11-time.to_s.length)
|
63
|
+
end
|
64
|
+
|
65
|
+
end
|
66
|
+
|
67
|
+
end
|
data/lib/turn/minitest.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# make sure latest verison is used, rather than ruby's built-in
|
2
2
|
begin
|
3
|
-
gem 'minitest'
|
4
|
-
rescue
|
3
|
+
gem 'minitest', '< 5.0.0'
|
4
|
+
rescue Gem::LoadError
|
5
5
|
warn "gem install minitest"
|
6
6
|
end
|
7
7
|
|
@@ -20,7 +20,6 @@ if MiniTest::Unit.respond_to?(:runner=)
|
|
20
20
|
MiniTest::Unit.runner = Turn::MiniRunner.new
|
21
21
|
else
|
22
22
|
raise "MiniTest v#{MiniTest::Unit::VERSION} is out of date.\n" \
|
23
|
-
"
|
23
|
+
"Please update to a newer version, but version 5.0.0 or above will not work. ."
|
24
24
|
#MiniTest::Unit = Turn::MiniRunner
|
25
25
|
end
|
26
|
-
|
data/lib/turn/reporter.rb
CHANGED
@@ -70,9 +70,9 @@ module Turn
|
|
70
70
|
# suites are cases in minitest
|
71
71
|
@turn_case = @turn_suite.new_case(suite.name)
|
72
72
|
|
73
|
-
filter = @options[:filter] || @turn_config.pattern || /./
|
73
|
+
filter = normalize_filter(@options[:filter]) || @turn_config.pattern || /./
|
74
74
|
|
75
|
-
suite.send("#{type}_methods").grep(filter).each do |test|
|
75
|
+
suite.send("#{type}_methods").grep(/#{filter}/).each do |test|
|
76
76
|
@turn_case.new_test(test)
|
77
77
|
end
|
78
78
|
|
@@ -122,6 +122,14 @@ module Turn
|
|
122
122
|
super(klass, meth, err)
|
123
123
|
end
|
124
124
|
|
125
|
+
private
|
126
|
+
|
127
|
+
# regex gets turned into a string literal with leading/trailing slashes
|
128
|
+
# so remove them
|
129
|
+
def normalize_filter(filter)
|
130
|
+
filter.sub(/^(\/)/, '').sub(/(\/)$/, '') if filter
|
131
|
+
end
|
132
|
+
|
125
133
|
end
|
126
134
|
|
127
135
|
end
|
data/lib/turn/version.rb
CHANGED
data/test/helper.rb
CHANGED
@@ -118,6 +118,24 @@ end
|
|
118
118
|
save_test(text, 'outline_test.rb')
|
119
119
|
end
|
120
120
|
|
121
|
+
def setup_minispec
|
122
|
+
text = <<-HERE
|
123
|
+
require 'turn'
|
124
|
+
require 'minitest/autorun'
|
125
|
+
|
126
|
+
describe 'multiple tests' do
|
127
|
+
it 'should pass' do
|
128
|
+
assert true
|
129
|
+
end
|
130
|
+
|
131
|
+
it 'should fail' do
|
132
|
+
assert false
|
133
|
+
end
|
134
|
+
end
|
135
|
+
HERE
|
136
|
+
save_test(text, 'minispec_test.rb')
|
137
|
+
end
|
138
|
+
|
121
139
|
#
|
122
140
|
def setup_minitest_autorun
|
123
141
|
text = <<-HERE
|
data/test/test_runners.rb
CHANGED
@@ -18,6 +18,15 @@ class TestRunners < Test::Unit::TestCase
|
|
18
18
|
assert result.index('0 errors'), "ACTUAL RESULT:\n #{result}"
|
19
19
|
end
|
20
20
|
|
21
|
+
def test_minispec_name
|
22
|
+
file = setup_minispec
|
23
|
+
result = turn2 '-n "/fail/"', file
|
24
|
+
|
25
|
+
assert result.index('0 passed'), "ACTUAL RESULT:\n #{result}"
|
26
|
+
assert result.index('1 failures'), "ACTUAL RESULT:\n #{result}"
|
27
|
+
assert result.index('1 assertions'), "ACTUAL RESULT:\n #{result}"
|
28
|
+
end
|
29
|
+
|
21
30
|
# autorun
|
22
31
|
|
23
32
|
#if RUBY_VERSION < '1.9'
|
@@ -30,6 +39,15 @@ class TestRunners < Test::Unit::TestCase
|
|
30
39
|
assert(result.index('0 errors'), "ACTUAL RESULT:\n #{result}")
|
31
40
|
end
|
32
41
|
|
42
|
+
def test_autorun_minispec_name
|
43
|
+
file = setup_minispec
|
44
|
+
result = `ruby -Ilib #{file} -n "/fail/" 2>&1`
|
45
|
+
|
46
|
+
assert result.index('0 passed'), "ACTUAL RESULT:\n #{result}"
|
47
|
+
assert result.index('1 failures'), "ACTUAL RESULT:\n #{result}"
|
48
|
+
assert result.index('1 assertions'), "ACTUAL RESULT:\n #{result}"
|
49
|
+
end
|
50
|
+
|
33
51
|
#else
|
34
52
|
|
35
53
|
def test_autorun
|
@@ -39,6 +57,15 @@ class TestRunners < Test::Unit::TestCase
|
|
39
57
|
assert result.index('0 errors'), "ACTUAL RESULT:\n #{result}"
|
40
58
|
end
|
41
59
|
|
60
|
+
def test_autorun_minitest_name
|
61
|
+
file = setup_minitest_autorun
|
62
|
+
result = `ruby -Ilib #{file} -n "/sample/" 2>&1`
|
63
|
+
|
64
|
+
assert result.index('1 passed'), "ACTUAL RESULT:\n #{result}"
|
65
|
+
assert result.index('1 assertions'), "ACTUAL RESULT:\n #{result}"
|
66
|
+
end
|
67
|
+
|
68
|
+
|
42
69
|
def test_autorun_with_trace
|
43
70
|
file = setup_minitest_autorun_with_trace
|
44
71
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: turn
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.7
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2014-03-14 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: ansi
|
@@ -30,6 +30,22 @@ dependencies:
|
|
30
30
|
version: '0'
|
31
31
|
- !ruby/object:Gem::Dependency
|
32
32
|
name: minitest
|
33
|
+
requirement: !ruby/object:Gem::Requirement
|
34
|
+
none: false
|
35
|
+
requirements:
|
36
|
+
- - ~>
|
37
|
+
- !ruby/object:Gem::Version
|
38
|
+
version: '4'
|
39
|
+
type: :runtime
|
40
|
+
prerelease: false
|
41
|
+
version_requirements: !ruby/object:Gem::Requirement
|
42
|
+
none: false
|
43
|
+
requirements:
|
44
|
+
- - ~>
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '4'
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: rake
|
33
49
|
requirement: !ruby/object:Gem::Requirement
|
34
50
|
none: false
|
35
51
|
requirements:
|
@@ -45,7 +61,23 @@ dependencies:
|
|
45
61
|
- !ruby/object:Gem::Version
|
46
62
|
version: '0'
|
47
63
|
- !ruby/object:Gem::Dependency
|
48
|
-
name:
|
64
|
+
name: indexer
|
65
|
+
requirement: !ruby/object:Gem::Requirement
|
66
|
+
none: false
|
67
|
+
requirements:
|
68
|
+
- - ! '>='
|
69
|
+
- !ruby/object:Gem::Version
|
70
|
+
version: '0'
|
71
|
+
type: :development
|
72
|
+
prerelease: false
|
73
|
+
version_requirements: !ruby/object:Gem::Requirement
|
74
|
+
none: false
|
75
|
+
requirements:
|
76
|
+
- - ! '>='
|
77
|
+
- !ruby/object:Gem::Version
|
78
|
+
version: '0'
|
79
|
+
- !ruby/object:Gem::Dependency
|
80
|
+
name: mast
|
49
81
|
requirement: !ruby/object:Gem::Requirement
|
50
82
|
none: false
|
51
83
|
requirements:
|
@@ -70,12 +102,11 @@ executables:
|
|
70
102
|
extensions: []
|
71
103
|
extra_rdoc_files:
|
72
104
|
- History.txt
|
73
|
-
- Version.txt
|
74
|
-
- LICENSE-GPL2.txt
|
75
|
-
- LICENSE-RUBY.txt
|
76
|
-
- LICENSE-MIT.txt
|
77
|
-
- Release.txt
|
78
105
|
- LICENSE.txt
|
106
|
+
- Release.txt
|
107
|
+
- Version.txt
|
108
|
+
- CONTRIBUTING.md
|
109
|
+
- NOTICE.md
|
79
110
|
- README.md
|
80
111
|
files:
|
81
112
|
- bin/turn
|
@@ -91,6 +122,7 @@ files:
|
|
91
122
|
- lib/turn/configuration.rb
|
92
123
|
- lib/turn/controller.rb
|
93
124
|
- lib/turn/core_ext.rb
|
125
|
+
- lib/turn/decorators/topten_decorator.rb
|
94
126
|
- lib/turn/minitest.rb
|
95
127
|
- lib/turn/reporter.rb
|
96
128
|
- lib/turn/reporters/cue_reporter.rb
|
@@ -119,17 +151,18 @@ files:
|
|
119
151
|
- try/test_counts.rb
|
120
152
|
- try/test_sample.rb
|
121
153
|
- try/test_sample2.rb
|
122
|
-
-
|
154
|
+
- CONTRIBUTING.md
|
123
155
|
- Release.txt
|
124
|
-
- LICENSE.txt
|
125
156
|
- Version.txt
|
126
|
-
-
|
127
|
-
-
|
128
|
-
- LICENSE-GPL2.txt
|
157
|
+
- NOTICE.md
|
158
|
+
- Index.rb
|
129
159
|
- History.txt
|
160
|
+
- README.md
|
161
|
+
- LICENSE.txt
|
130
162
|
homepage: http://rubygems.org/gems/turn
|
131
163
|
licenses:
|
132
164
|
- MIT
|
165
|
+
- MIT
|
133
166
|
post_install_message:
|
134
167
|
rdoc_options: []
|
135
168
|
require_paths:
|
@@ -148,9 +181,14 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
148
181
|
version: '0'
|
149
182
|
requirements: []
|
150
183
|
rubyforge_project:
|
151
|
-
rubygems_version: 1.8.
|
184
|
+
rubygems_version: 1.8.23
|
152
185
|
signing_key:
|
153
186
|
specification_version: 3
|
154
187
|
summary: Test Reporters (New) -- new output formats for Testing
|
155
188
|
test_files:
|
189
|
+
- test/helper.rb
|
156
190
|
- test/reporter_test.rb
|
191
|
+
- test/test_framework.rb
|
192
|
+
- test/test_reporters.rb
|
193
|
+
- test/test_runners.rb
|
194
|
+
has_rdoc:
|
data/LICENSE-GPL2.txt
DELETED
@@ -1,340 +0,0 @@
|
|
1
|
-
GNU GENERAL PUBLIC LICENSE
|
2
|
-
Version 2, June 1991
|
3
|
-
|
4
|
-
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
|
5
|
-
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
6
|
-
Everyone is permitted to copy and distribute verbatim copies
|
7
|
-
of this license document, but changing it is not allowed.
|
8
|
-
|
9
|
-
Preamble
|
10
|
-
|
11
|
-
The licenses for most software are designed to take away your
|
12
|
-
freedom to share and change it. By contrast, the GNU General Public
|
13
|
-
License is intended to guarantee your freedom to share and change free
|
14
|
-
software--to make sure the software is free for all its users. This
|
15
|
-
General Public License applies to most of the Free Software
|
16
|
-
Foundation's software and to any other program whose authors commit to
|
17
|
-
using it. (Some other Free Software Foundation software is covered by
|
18
|
-
the GNU Library General Public License instead.) You can apply it to
|
19
|
-
your programs, too.
|
20
|
-
|
21
|
-
When we speak of free software, we are referring to freedom, not
|
22
|
-
price. Our General Public Licenses are designed to make sure that you
|
23
|
-
have the freedom to distribute copies of free software (and charge for
|
24
|
-
this service if you wish), that you receive source code or can get it
|
25
|
-
if you want it, that you can change the software or use pieces of it
|
26
|
-
in new free programs; and that you know you can do these things.
|
27
|
-
|
28
|
-
To protect your rights, we need to make restrictions that forbid
|
29
|
-
anyone to deny you these rights or to ask you to surrender the rights.
|
30
|
-
These restrictions translate to certain responsibilities for you if you
|
31
|
-
distribute copies of the software, or if you modify it.
|
32
|
-
|
33
|
-
For example, if you distribute copies of such a program, whether
|
34
|
-
gratis or for a fee, you must give the recipients all the rights that
|
35
|
-
you have. You must make sure that they, too, receive or can get the
|
36
|
-
source code. And you must show them these terms so they know their
|
37
|
-
rights.
|
38
|
-
|
39
|
-
We protect your rights with two steps: (1) copyright the software, and
|
40
|
-
(2) offer you this license which gives you legal permission to copy,
|
41
|
-
distribute and/or modify the software.
|
42
|
-
|
43
|
-
Also, for each author's protection and ours, we want to make certain
|
44
|
-
that everyone understands that there is no warranty for this free
|
45
|
-
software. If the software is modified by someone else and passed on, we
|
46
|
-
want its recipients to know that what they have is not the original, so
|
47
|
-
that any problems introduced by others will not reflect on the original
|
48
|
-
authors' reputations.
|
49
|
-
|
50
|
-
Finally, any free program is threatened constantly by software
|
51
|
-
patents. We wish to avoid the danger that redistributors of a free
|
52
|
-
program will individually obtain patent licenses, in effect making the
|
53
|
-
program proprietary. To prevent this, we have made it clear that any
|
54
|
-
patent must be licensed for everyone's free use or not licensed at all.
|
55
|
-
|
56
|
-
The precise terms and conditions for copying, distribution and
|
57
|
-
modification follow.
|
58
|
-
|
59
|
-
GNU GENERAL PUBLIC LICENSE
|
60
|
-
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
61
|
-
|
62
|
-
0. This License applies to any program or other work which contains
|
63
|
-
a notice placed by the copyright holder saying it may be distributed
|
64
|
-
under the terms of this General Public License. The "Program", below,
|
65
|
-
refers to any such program or work, and a "work based on the Program"
|
66
|
-
means either the Program or any derivative work under copyright law:
|
67
|
-
that is to say, a work containing the Program or a portion of it,
|
68
|
-
either verbatim or with modifications and/or translated into another
|
69
|
-
language. (Hereinafter, translation is included without limitation in
|
70
|
-
the term "modification".) Each licensee is addressed as "you".
|
71
|
-
|
72
|
-
Activities other than copying, distribution and modification are not
|
73
|
-
covered by this License; they are outside its scope. The act of
|
74
|
-
running the Program is not restricted, and the output from the Program
|
75
|
-
is covered only if its contents constitute a work based on the
|
76
|
-
Program (independent of having been made by running the Program).
|
77
|
-
Whether that is true depends on what the Program does.
|
78
|
-
|
79
|
-
1. You may copy and distribute verbatim copies of the Program's
|
80
|
-
source code as you receive it, in any medium, provided that you
|
81
|
-
conspicuously and appropriately publish on each copy an appropriate
|
82
|
-
copyright notice and disclaimer of warranty; keep intact all the
|
83
|
-
notices that refer to this License and to the absence of any warranty;
|
84
|
-
and give any other recipients of the Program a copy of this License
|
85
|
-
along with the Program.
|
86
|
-
|
87
|
-
You may charge a fee for the physical act of transferring a copy, and
|
88
|
-
you may at your option offer warranty protection in exchange for a fee.
|
89
|
-
|
90
|
-
2. You may modify your copy or copies of the Program or any portion
|
91
|
-
of it, thus forming a work based on the Program, and copy and
|
92
|
-
distribute such modifications or work under the terms of Section 1
|
93
|
-
above, provided that you also meet all of these conditions:
|
94
|
-
|
95
|
-
a) You must cause the modified files to carry prominent notices
|
96
|
-
stating that you changed the files and the date of any change.
|
97
|
-
|
98
|
-
b) You must cause any work that you distribute or publish, that in
|
99
|
-
whole or in part contains or is derived from the Program or any
|
100
|
-
part thereof, to be licensed as a whole at no charge to all third
|
101
|
-
parties under the terms of this License.
|
102
|
-
|
103
|
-
c) If the modified program normally reads commands interactively
|
104
|
-
when run, you must cause it, when started running for such
|
105
|
-
interactive use in the most ordinary way, to print or display an
|
106
|
-
announcement including an appropriate copyright notice and a
|
107
|
-
notice that there is no warranty (or else, saying that you provide
|
108
|
-
a warranty) and that users may redistribute the program under
|
109
|
-
these conditions, and telling the user how to view a copy of this
|
110
|
-
License. (Exception: if the Program itself is interactive but
|
111
|
-
does not normally print such an announcement, your work based on
|
112
|
-
the Program is not required to print an announcement.)
|
113
|
-
|
114
|
-
These requirements apply to the modified work as a whole. If
|
115
|
-
identifiable sections of that work are not derived from the Program,
|
116
|
-
and can be reasonably considered independent and separate works in
|
117
|
-
themselves, then this License, and its terms, do not apply to those
|
118
|
-
sections when you distribute them as separate works. But when you
|
119
|
-
distribute the same sections as part of a whole which is a work based
|
120
|
-
on the Program, the distribution of the whole must be on the terms of
|
121
|
-
this License, whose permissions for other licensees extend to the
|
122
|
-
entire whole, and thus to each and every part regardless of who wrote it.
|
123
|
-
|
124
|
-
Thus, it is not the intent of this section to claim rights or contest
|
125
|
-
your rights to work written entirely by you; rather, the intent is to
|
126
|
-
exercise the right to control the distribution of derivative or
|
127
|
-
collective works based on the Program.
|
128
|
-
|
129
|
-
In addition, mere aggregation of another work not based on the Program
|
130
|
-
with the Program (or with a work based on the Program) on a volume of
|
131
|
-
a storage or distribution medium does not bring the other work under
|
132
|
-
the scope of this License.
|
133
|
-
|
134
|
-
3. You may copy and distribute the Program (or a work based on it,
|
135
|
-
under Section 2) in object code or executable form under the terms of
|
136
|
-
Sections 1 and 2 above provided that you also do one of the following:
|
137
|
-
|
138
|
-
a) Accompany it with the complete corresponding machine-readable
|
139
|
-
source code, which must be distributed under the terms of Sections
|
140
|
-
1 and 2 above on a medium customarily used for software interchange; or,
|
141
|
-
|
142
|
-
b) Accompany it with a written offer, valid for at least three
|
143
|
-
years, to give any third party, for a charge no more than your
|
144
|
-
cost of physically performing source distribution, a complete
|
145
|
-
machine-readable copy of the corresponding source code, to be
|
146
|
-
distributed under the terms of Sections 1 and 2 above on a medium
|
147
|
-
customarily used for software interchange; or,
|
148
|
-
|
149
|
-
c) Accompany it with the information you received as to the offer
|
150
|
-
to distribute corresponding source code. (This alternative is
|
151
|
-
allowed only for noncommercial distribution and only if you
|
152
|
-
received the program in object code or executable form with such
|
153
|
-
an offer, in accord with Subsection b above.)
|
154
|
-
|
155
|
-
The source code for a work means the preferred form of the work for
|
156
|
-
making modifications to it. For an executable work, complete source
|
157
|
-
code means all the source code for all modules it contains, plus any
|
158
|
-
associated interface definition files, plus the scripts used to
|
159
|
-
control compilation and installation of the executable. However, as a
|
160
|
-
special exception, the source code distributed need not include
|
161
|
-
anything that is normally distributed (in either source or binary
|
162
|
-
form) with the major components (compiler, kernel, and so on) of the
|
163
|
-
operating system on which the executable runs, unless that component
|
164
|
-
itself accompanies the executable.
|
165
|
-
|
166
|
-
If distribution of executable or object code is made by offering
|
167
|
-
access to copy from a designated place, then offering equivalent
|
168
|
-
access to copy the source code from the same place counts as
|
169
|
-
distribution of the source code, even though third parties are not
|
170
|
-
compelled to copy the source along with the object code.
|
171
|
-
|
172
|
-
4. You may not copy, modify, sublicense, or distribute the Program
|
173
|
-
except as expressly provided under this License. Any attempt
|
174
|
-
otherwise to copy, modify, sublicense or distribute the Program is
|
175
|
-
void, and will automatically terminate your rights under this License.
|
176
|
-
However, parties who have received copies, or rights, from you under
|
177
|
-
this License will not have their licenses terminated so long as such
|
178
|
-
parties remain in full compliance.
|
179
|
-
|
180
|
-
5. You are not required to accept this License, since you have not
|
181
|
-
signed it. However, nothing else grants you permission to modify or
|
182
|
-
distribute the Program or its derivative works. These actions are
|
183
|
-
prohibited by law if you do not accept this License. Therefore, by
|
184
|
-
modifying or distributing the Program (or any work based on the
|
185
|
-
Program), you indicate your acceptance of this License to do so, and
|
186
|
-
all its terms and conditions for copying, distributing or modifying
|
187
|
-
the Program or works based on it.
|
188
|
-
|
189
|
-
6. Each time you redistribute the Program (or any work based on the
|
190
|
-
Program), the recipient automatically receives a license from the
|
191
|
-
original licensor to copy, distribute or modify the Program subject to
|
192
|
-
these terms and conditions. You may not impose any further
|
193
|
-
restrictions on the recipients' exercise of the rights granted herein.
|
194
|
-
You are not responsible for enforcing compliance by third parties to
|
195
|
-
this License.
|
196
|
-
|
197
|
-
7. If, as a consequence of a court judgment or allegation of patent
|
198
|
-
infringement or for any other reason (not limited to patent issues),
|
199
|
-
conditions are imposed on you (whether by court order, agreement or
|
200
|
-
otherwise) that contradict the conditions of this License, they do not
|
201
|
-
excuse you from the conditions of this License. If you cannot
|
202
|
-
distribute so as to satisfy simultaneously your obligations under this
|
203
|
-
License and any other pertinent obligations, then as a consequence you
|
204
|
-
may not distribute the Program at all. For example, if a patent
|
205
|
-
license would not permit royalty-free redistribution of the Program by
|
206
|
-
all those who receive copies directly or indirectly through you, then
|
207
|
-
the only way you could satisfy both it and this License would be to
|
208
|
-
refrain entirely from distribution of the Program.
|
209
|
-
|
210
|
-
If any portion of this section is held invalid or unenforceable under
|
211
|
-
any particular circumstance, the balance of the section is intended to
|
212
|
-
apply and the section as a whole is intended to apply in other
|
213
|
-
circumstances.
|
214
|
-
|
215
|
-
It is not the purpose of this section to induce you to infringe any
|
216
|
-
patents or other property right claims or to contest validity of any
|
217
|
-
such claims; this section has the sole purpose of protecting the
|
218
|
-
integrity of the free software distribution system, which is
|
219
|
-
implemented by public license practices. Many people have made
|
220
|
-
generous contributions to the wide range of software distributed
|
221
|
-
through that system in reliance on consistent application of that
|
222
|
-
system; it is up to the author/donor to decide if he or she is willing
|
223
|
-
to distribute software through any other system and a licensee cannot
|
224
|
-
impose that choice.
|
225
|
-
|
226
|
-
This section is intended to make thoroughly clear what is believed to
|
227
|
-
be a consequence of the rest of this License.
|
228
|
-
|
229
|
-
8. If the distribution and/or use of the Program is restricted in
|
230
|
-
certain countries either by patents or by copyrighted interfaces, the
|
231
|
-
original copyright holder who places the Program under this License
|
232
|
-
may add an explicit geographical distribution limitation excluding
|
233
|
-
those countries, so that distribution is permitted only in or among
|
234
|
-
countries not thus excluded. In such case, this License incorporates
|
235
|
-
the limitation as if written in the body of this License.
|
236
|
-
|
237
|
-
9. The Free Software Foundation may publish revised and/or new versions
|
238
|
-
of the General Public License from time to time. Such new versions will
|
239
|
-
be similar in spirit to the present version, but may differ in detail to
|
240
|
-
address new problems or concerns.
|
241
|
-
|
242
|
-
Each version is given a distinguishing version number. If the Program
|
243
|
-
specifies a version number of this License which applies to it and "any
|
244
|
-
later version", you have the option of following the terms and conditions
|
245
|
-
either of that version or of any later version published by the Free
|
246
|
-
Software Foundation. If the Program does not specify a version number of
|
247
|
-
this License, you may choose any version ever published by the Free Software
|
248
|
-
Foundation.
|
249
|
-
|
250
|
-
10. If you wish to incorporate parts of the Program into other free
|
251
|
-
programs whose distribution conditions are different, write to the author
|
252
|
-
to ask for permission. For software which is copyrighted by the Free
|
253
|
-
Software Foundation, write to the Free Software Foundation; we sometimes
|
254
|
-
make exceptions for this. Our decision will be guided by the two goals
|
255
|
-
of preserving the free status of all derivatives of our free software and
|
256
|
-
of promoting the sharing and reuse of software generally.
|
257
|
-
|
258
|
-
NO WARRANTY
|
259
|
-
|
260
|
-
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
|
261
|
-
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
|
262
|
-
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
|
263
|
-
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
|
264
|
-
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
265
|
-
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
|
266
|
-
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
267
|
-
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
|
268
|
-
REPAIR OR CORRECTION.
|
269
|
-
|
270
|
-
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
271
|
-
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
|
272
|
-
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
273
|
-
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
|
274
|
-
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
|
275
|
-
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
|
276
|
-
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
|
277
|
-
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
278
|
-
POSSIBILITY OF SUCH DAMAGES.
|
279
|
-
|
280
|
-
END OF TERMS AND CONDITIONS
|
281
|
-
|
282
|
-
How to Apply These Terms to Your New Programs
|
283
|
-
|
284
|
-
If you develop a new program, and you want it to be of the greatest
|
285
|
-
possible use to the public, the best way to achieve this is to make it
|
286
|
-
free software which everyone can redistribute and change under these terms.
|
287
|
-
|
288
|
-
To do so, attach the following notices to the program. It is safest
|
289
|
-
to attach them to the start of each source file to most effectively
|
290
|
-
convey the exclusion of warranty; and each file should have at least
|
291
|
-
the "copyright" line and a pointer to where the full notice is found.
|
292
|
-
|
293
|
-
<one line to give the program's name and a brief idea of what it does.>
|
294
|
-
Copyright (C) <year> <name of author>
|
295
|
-
|
296
|
-
This program is free software; you can redistribute it and/or modify
|
297
|
-
it under the terms of the GNU General Public License as published by
|
298
|
-
the Free Software Foundation; either version 2 of the License, or
|
299
|
-
(at your option) any later version.
|
300
|
-
|
301
|
-
This program is distributed in the hope that it will be useful,
|
302
|
-
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
303
|
-
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
304
|
-
GNU General Public License for more details.
|
305
|
-
|
306
|
-
You should have received a copy of the GNU General Public License
|
307
|
-
along with this program; if not, write to the Free Software
|
308
|
-
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
309
|
-
|
310
|
-
|
311
|
-
Also add information on how to contact you by electronic and paper mail.
|
312
|
-
|
313
|
-
If the program is interactive, make it output a short notice like this
|
314
|
-
when it starts in an interactive mode:
|
315
|
-
|
316
|
-
Gnomovision version 69, Copyright (C) year name of author
|
317
|
-
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
318
|
-
This is free software, and you are welcome to redistribute it
|
319
|
-
under certain conditions; type `show c' for details.
|
320
|
-
|
321
|
-
The hypothetical commands `show w' and `show c' should show the appropriate
|
322
|
-
parts of the General Public License. Of course, the commands you use may
|
323
|
-
be called something other than `show w' and `show c'; they could even be
|
324
|
-
mouse-clicks or menu items--whatever suits your program.
|
325
|
-
|
326
|
-
You should also get your employer (if you work as a programmer) or your
|
327
|
-
school, if any, to sign a "copyright disclaimer" for the program, if
|
328
|
-
necessary. Here is a sample; alter the names:
|
329
|
-
|
330
|
-
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
|
331
|
-
`Gnomovision' (which makes passes at compilers) written by James Hacker.
|
332
|
-
|
333
|
-
<signature of Ty Coon>, 1 April 1989
|
334
|
-
Ty Coon, President of Vice
|
335
|
-
|
336
|
-
This General Public License does not permit incorporating your program into
|
337
|
-
proprietary programs. If your program is a subroutine library, you may
|
338
|
-
consider it more useful to permit linking proprietary applications with the
|
339
|
-
library. If this is what you want to do, use the GNU Library General
|
340
|
-
Public License instead of this License.
|
data/LICENSE-MIT.txt
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
MIT License
|
2
|
-
|
3
|
-
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
-
a copy of this software and associated documentation files (the
|
5
|
-
'Software'), to deal in the Software without restriction, including
|
6
|
-
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
-
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
-
permit persons to whom the Software is furnished to do so, subject to
|
9
|
-
the following conditions:
|
10
|
-
|
11
|
-
The above copyright notice and this permission notice shall be
|
12
|
-
included in all copies or substantial portions of the Software.
|
13
|
-
|
14
|
-
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
15
|
-
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
-
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
17
|
-
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
18
|
-
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
19
|
-
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
20
|
-
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
21
|
-
|
data/LICENSE-RUBY.txt
DELETED
@@ -1,56 +0,0 @@
|
|
1
|
-
Ruby is copyrighted free software by Yukihiro Matsumoto <matz@netlab.jp>.
|
2
|
-
You can redistribute it and/or modify it under either the terms of the GPL
|
3
|
-
version 2 (see the file GPL), or the conditions below:
|
4
|
-
|
5
|
-
1. You may make and give away verbatim copies of the source form of the
|
6
|
-
software without restriction, provided that you duplicate all of the
|
7
|
-
original copyright notices and associated disclaimers.
|
8
|
-
|
9
|
-
2. You may modify your copy of the software in any way, provided that
|
10
|
-
you do at least ONE of the following:
|
11
|
-
|
12
|
-
a) place your modifications in the Public Domain or otherwise
|
13
|
-
make them Freely Available, such as by posting said
|
14
|
-
modifications to Usenet or an equivalent medium, or by allowing
|
15
|
-
the author to include your modifications in the software.
|
16
|
-
|
17
|
-
b) use the modified software only within your corporation or
|
18
|
-
organization.
|
19
|
-
|
20
|
-
c) give non-standard binaries non-standard names, with
|
21
|
-
instructions on where to get the original software distribution.
|
22
|
-
|
23
|
-
d) make other distribution arrangements with the author.
|
24
|
-
|
25
|
-
3. You may distribute the software in object code or binary form,
|
26
|
-
provided that you do at least ONE of the following:
|
27
|
-
|
28
|
-
a) distribute the binaries and library files of the software,
|
29
|
-
together with instructions (in the manual page or equivalent)
|
30
|
-
on where to get the original distribution.
|
31
|
-
|
32
|
-
b) accompany the distribution with the machine-readable source of
|
33
|
-
the software.
|
34
|
-
|
35
|
-
c) give non-standard binaries non-standard names, with
|
36
|
-
instructions on where to get the original software distribution.
|
37
|
-
|
38
|
-
d) make other distribution arrangements with the author.
|
39
|
-
|
40
|
-
4. You may modify and include the part of the software into any other
|
41
|
-
software (possibly commercial). But some files in the distribution
|
42
|
-
are not written by the author, so that they are not under these terms.
|
43
|
-
|
44
|
-
For the list of those files and their copying conditions, see the
|
45
|
-
file LEGAL.
|
46
|
-
|
47
|
-
5. The scripts and library files supplied as input to or produced as
|
48
|
-
output from the software do not automatically fall under the
|
49
|
-
copyright of the software, but belong to whomever generated them,
|
50
|
-
and may be sold commercially, and may be aggregated with this
|
51
|
-
software.
|
52
|
-
|
53
|
-
6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
|
54
|
-
IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
55
|
-
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
56
|
-
PURPOSE.
|