dohtest 0.1.40 → 0.1.41

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: ff92bb0fee52aed522aef021600b36168d9dec7f
4
- data.tar.gz: 6c77c2042c170be86917f2a922370bb9e9784a7b
3
+ metadata.gz: a4ca4a740755c62d6760eef5870d9f4d4039ad2d
4
+ data.tar.gz: 20415076314938d7b72e895720f10ff0897036a5
5
5
  SHA512:
6
- metadata.gz: e41971fcab4302428670a1e28f7cf8f97af64d5448b6f7de68c38f9f32bf0738d8fff274abe8a1116217301f1c621d5fee123add1fd151ee8a279d515d827278
7
- data.tar.gz: e623e91b3046ae6a6fa480f413f06d1f9461be6853353481eeef3bc6f571c1a34803acc5f39c650d497ce2d2efc2631c2d3767e1c3f5aac9840cfdd9978c8d70
6
+ metadata.gz: 4fc60972dd241b3477187c73b77f8e4eda3ccc77e42c05c620e0867f6a9e46ba861bbedb901e0f0470e5d846136b86bed5eeefc39987700f7cb35dbf8ea36cb2
7
+ data.tar.gz: 9f443888921ff38fac0cec049d8d7deb8bd3f811731d2b12386ff04041d402e9923b5ff31b13caf2f1255c3b9fc5b40c7bca6d6f79f1dddfed535e0197c6c3b9
@@ -4,7 +4,7 @@ module DohTest
4
4
  extend self
5
5
 
6
6
  def config
7
- @config ||= {:post_all_callback => []}
7
+ @config ||= {:post_all_callback => [], :pre_group_callback => [], :post_group_callback => [], :pre_test_callback => []}
8
8
  end
9
9
 
10
10
  def find_root(start_directory, max_tries = 20)
@@ -38,10 +38,10 @@ class GroupRunner
38
38
 
39
39
  def run_before_all
40
40
  @group.before_all if @group.respond_to?(:before_all)
41
- if @config[:pre_group_callback]
42
- if (!@config[:pre_group_callback].call())
41
+ @config[:pre_group_callback].each do |callback|
42
+ if (!callback.call(@group))
43
43
  @error_count += 1
44
- @output.callback_failed(@config[:pre_group_callback].inspect)
44
+ @output.callback_failed(callback.inspect)
45
45
  end
46
46
  end
47
47
  rescue => error
@@ -51,10 +51,10 @@ class GroupRunner
51
51
 
52
52
  def run_after_all
53
53
  @group.after_all if @group.respond_to?(:after_all)
54
- if @config[:post_group_callback]
55
- if (!@config[:post_group_callback].call(total_problems))
54
+ @config[:post_group_callback].each do |callback|
55
+ if (!callback.call(total_problems))
56
56
  @error_count += 1
57
- @output.callback_failed(@config[:post_group_callback].inspect)
57
+ @output.callback_failed(callback.inspect)
58
58
  end
59
59
  end
60
60
  rescue => error
@@ -10,7 +10,9 @@ class MasterRunner
10
10
 
11
11
  def run
12
12
  start_time = Time.now
13
- @config[:pre_test_callback].call(@output) if @config[:pre_test_callback]
13
+ @config[:pre_test_callback].each do |callback|
14
+ callback.call(@output)
15
+ end
14
16
  if @paths.empty?
15
17
  unless DohTest.require_paths(@config[:glob], ['.'])
16
18
  DohTest.require_paths(@config[:glob], [@config[:root]])
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dohtest
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.40
4
+ version: 0.1.41
5
5
  platform: ruby
6
6
  authors:
7
7
  - Makani Mason
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-12-31 00:00:00.000000000 Z
12
+ date: 2014-05-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: dohroot