codeclimate-parallel-test-reporter 0.0.2

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.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: cf5ab9d6c69e03fe6de278621af1332f731f88d0
4
+ data.tar.gz: 7242b8f1f5ffaf23cd67eca4c48cf5045a45d2c8
5
+ SHA512:
6
+ metadata.gz: 4313b75cf4b9b923526ff2c46fdc2fd09b6e6651ee1504b8780e369ec09089afd34250b9c801acf23f9c7c8134190fdd2df7185f2c98b52426ae870ce7fa6808
7
+ data.tar.gz: ea9cee36a9b46474f79120da8269b5b8edaad22f1e62c026d62bb140a681194d2a4a1a5279b2afd0220e2326c3b49aa72482cb3d7754c03f57d1872c4327f63e
@@ -0,0 +1,22 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
18
+ *.bundle
19
+ *.so
20
+ *.o
21
+ *.a
22
+ mkmf.log
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --color
2
+ --format progress
data/Gemfile ADDED
@@ -0,0 +1,11 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in codeclimate-parallel-test-reporter.gemspec
4
+ gemspec
5
+
6
+
7
+ group :test do
8
+ gem 'pry-debugger'
9
+
10
+ gem 'rspec'
11
+ end
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2014 Michal Cichra
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,29 @@
1
+ # Codeclimate::Parallel::Test::Reporter
2
+
3
+ TODO: Write a gem description
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ gem 'codeclimate-parallel-test-reporter'
10
+
11
+ And then execute:
12
+
13
+ $ bundle
14
+
15
+ Or install it yourself as:
16
+
17
+ $ gem install codeclimate-parallel-test-reporter
18
+
19
+ ## Usage
20
+
21
+ TODO: Write usage instructions here
22
+
23
+ ## Contributing
24
+
25
+ 1. Fork it ( https://github.com/[my-github-username]/codeclimate-parallel-test-reporter/fork )
26
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
27
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
28
+ 4. Push to the branch (`git push origin my-new-feature`)
29
+ 5. Create a new Pull Request
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+
@@ -0,0 +1,22 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'code_climate/parallel/test_reporter'
4
+
5
+ if ARGV.empty?
6
+ warn 'pass command to run your tests as an argument to codeclimate-parallel-test-reporter'
7
+ exit 1
8
+ end
9
+
10
+ ENV['TO_FILE'] = '1'
11
+
12
+ ret = system *ARGV
13
+
14
+ unless system('cc-tddium-post-worker')
15
+ warn "reporting to codeclimate failed"
16
+ end
17
+
18
+ FileUtils.rm Dir.glob("#{Dir.tmpdir}/codeclimate-test-coverage-*")
19
+
20
+ exit ret
21
+
22
+
@@ -0,0 +1,25 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'code_climate/parallel/test_reporter/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "codeclimate-parallel-test-reporter"
8
+ spec.version = CodeClimate::Parallel::TestReporter::VERSION
9
+ spec.authors = ["Michal Cichra"]
10
+ spec.email = ["michal@o2h.cz"]
11
+ spec.summary = %q{Push parallel tests results to CodeClimate}
12
+ spec.description = %q{Wraps codeclimate-test-reporter to send parallel test results with ease}
13
+ spec.homepage = ""
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.6"
22
+ spec.add_development_dependency "rake"
23
+
24
+ spec.add_dependency 'codeclimate-test-reporter'
25
+ end
@@ -0,0 +1,15 @@
1
+ require 'code_climate/test_reporter'
2
+ require 'code_climate/parallel/test_reporter/configuration'
3
+ require 'code_climate/parallel/test_reporter/formatter'
4
+
5
+ CodeClimate::TestReporter.configure do |config|
6
+ config.parallel = true
7
+ end
8
+
9
+ module CodeClimate
10
+ module TestReporter
11
+ class Formatter
12
+ prepend Parallel::Formatter
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,17 @@
1
+ require 'code_climate/test_reporter/configuration'
2
+
3
+ module CodeClimate
4
+ module Parallel
5
+ module Configuration
6
+ attr_accessor :parallel
7
+ end
8
+ end
9
+
10
+ module TestReporter
11
+ class Configuration
12
+ include Parallel::Configuration
13
+ end
14
+ end
15
+ end
16
+
17
+
@@ -0,0 +1,13 @@
1
+ require 'code_climate/test_reporter/ci'
2
+ require 'code_climate/test_reporter/formatter'
3
+
4
+ module CodeClimate
5
+ module Parallel
6
+ module Formatter
7
+ def partial?
8
+ CodeClimate::TestReporter.configuration.parallel
9
+ end
10
+ end
11
+ end
12
+ end
13
+
@@ -0,0 +1,7 @@
1
+ module CodeClimate
2
+ module Parallel
3
+ module TestReporter
4
+ VERSION = "0.0.2"
5
+ end
6
+ end
7
+ end
@@ -0,0 +1,5 @@
1
+ if ENV['CODECLIMATE_REPO_TOKEN']
2
+ require 'codeclimate-test-reporter'
3
+ require 'code_climate/parallel/test_reporter'
4
+ CodeClimate::TestReporter.start
5
+ end
@@ -0,0 +1,14 @@
1
+ describe 'codeclimate-parallel-test-reporter' do
2
+
3
+ def run(*args)
4
+ system(subject, *args)
5
+ end
6
+
7
+ it 'quits without params' do
8
+ expect(run).not_to be
9
+ end
10
+
11
+ it 'works with echo' do
12
+ expect(run('echo')).to be
13
+ end
14
+ end
@@ -0,0 +1,7 @@
1
+ require 'spec_helper'
2
+
3
+ require 'code_climate/parallel/test_reporter'
4
+
5
+ describe CodeClimate::TestReporter::Formatter do
6
+ it { should be_partial }
7
+ end
@@ -0,0 +1,21 @@
1
+ require 'bundler/setup'
2
+ Bundler.require(:default, :development, :test)
3
+
4
+ # This file was generated by the `rspec --init` command. Conventionally, all
5
+ # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
6
+ # Require this file using `require "spec_helper"` to ensure that it is only
7
+ # loaded once.
8
+ #
9
+ # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
10
+ RSpec.configure do |config|
11
+ config.treat_symbols_as_metadata_keys_with_true_values = true
12
+ config.run_all_when_everything_filtered = true
13
+ config.filter_run :focus
14
+
15
+ # Run specs in random order to surface order dependencies. If you find an
16
+ # order dependency and want to debug it, you can fix the order by providing
17
+ # the seed, which is printed after each run.
18
+ # --seed 1234
19
+ config.order = 'random'
20
+ end
21
+
metadata ADDED
@@ -0,0 +1,106 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: codeclimate-parallel-test-reporter
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.2
5
+ platform: ruby
6
+ authors:
7
+ - Michal Cichra
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-04-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ~>
18
+ - !ruby/object:Gem::Version
19
+ version: '1.6'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '1.6'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - '>='
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - '>='
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: codeclimate-test-reporter
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - '>='
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - '>='
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ description: Wraps codeclimate-test-reporter to send parallel test results with ease
56
+ email:
57
+ - michal@o2h.cz
58
+ executables:
59
+ - codeclimate-parallel-test-reporter
60
+ extensions: []
61
+ extra_rdoc_files: []
62
+ files:
63
+ - .gitignore
64
+ - .rspec
65
+ - Gemfile
66
+ - LICENSE.txt
67
+ - README.md
68
+ - Rakefile
69
+ - bin/codeclimate-parallel-test-reporter
70
+ - codeclimate-parallel-test-reporter.gemspec
71
+ - lib/code_climate/parallel/test_reporter.rb
72
+ - lib/code_climate/parallel/test_reporter/configuration.rb
73
+ - lib/code_climate/parallel/test_reporter/formatter.rb
74
+ - lib/code_climate/parallel/test_reporter/version.rb
75
+ - lib/codeclimate-parallel-test-reporter.rb
76
+ - spec/bin_spec.rb
77
+ - spec/parallel_test_reporter_formatter_spec.rb
78
+ - spec/spec_helper.rb
79
+ homepage: ''
80
+ licenses:
81
+ - MIT
82
+ metadata: {}
83
+ post_install_message:
84
+ rdoc_options: []
85
+ require_paths:
86
+ - lib
87
+ required_ruby_version: !ruby/object:Gem::Requirement
88
+ requirements:
89
+ - - '>='
90
+ - !ruby/object:Gem::Version
91
+ version: '0'
92
+ required_rubygems_version: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - '>='
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ requirements: []
98
+ rubyforge_project:
99
+ rubygems_version: 2.2.2
100
+ signing_key:
101
+ specification_version: 4
102
+ summary: Push parallel tests results to CodeClimate
103
+ test_files:
104
+ - spec/bin_spec.rb
105
+ - spec/parallel_test_reporter_formatter_spec.rb
106
+ - spec/spec_helper.rb