kanoah_rspec_formatter 0.2.6 → 0.2.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.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2b76ca8b325cc511371ae0d72354a6eed31a995b
|
4
|
+
data.tar.gz: 9c70e0dd0e4a868aa508f4cc562a003bebd8c3ce
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b4cd61b70bad2a80e35e830b106e95e0a461393e89d2b5350f85178f5e7fe0ec2d48aca3e7b9c96c790ef42d8ad7c449f9754900e566d79ce48cb6a5df26a787
|
7
|
+
data.tar.gz: e750e9166042dff88d736d26947adc779341d98f627a10a6da347150a5033abf7fa0e600d52c360c9a4805a2bb238dadcdc1f17c8a51431c4cceeee5645cbfa1
|
@@ -3,13 +3,8 @@ module KanoahRSpecFormatter
|
|
3
3
|
class BaseFormatter < RSpec::Core::Formatters::BaseFormatter
|
4
4
|
NOTIFICATIONS = %i[start example_started example_passed example_failed example_pending].freeze
|
5
5
|
|
6
|
-
def
|
7
|
-
@api = Kanoah::Client.new
|
8
|
-
project_id: KanoahRSpecFormatter::Config.config.project_id,
|
9
|
-
test_run_id: KanoahRSpecFormatter::Config.config.test_run_id,
|
10
|
-
environment: KanoahRSpecFormatter::Config.config.environment,
|
11
|
-
username: KanoahRSpecFormatter::Config.config.username,
|
12
|
-
password: KanoahRSpecFormatter::Config.config.password)
|
6
|
+
def start(notification)
|
7
|
+
@api = Kanoah::Client.new
|
13
8
|
end
|
14
9
|
end
|
15
10
|
end
|
@@ -11,17 +11,14 @@ class KanoahResultFormatter < KanoahRSpecFormatter::BaseFormatter
|
|
11
11
|
end
|
12
12
|
|
13
13
|
def example_passed(notification)
|
14
|
-
configure_api
|
15
14
|
proccess_result(notification.example) if notification.example.metadata.key?(:test_id) && !test_id(notification.example).empty?
|
16
15
|
end
|
17
16
|
|
18
17
|
def example_failed(notification)
|
19
|
-
configure_api
|
20
18
|
proccess_result(notification.example) if notification.example.metadata.key?(:test_id) && !test_id(notification.example).empty?
|
21
19
|
end
|
22
20
|
|
23
21
|
def example_pending(notification)
|
24
|
-
configure_api
|
25
22
|
proccess_result(notification.example) if notification.example.metadata.key?(:test_id) && !test_id(notification.example).empty?
|
26
23
|
end
|
27
24
|
|
@@ -1,7 +1,6 @@
|
|
1
1
|
require 'kanoah_ruby'
|
2
2
|
require 'rspec'
|
3
3
|
require_relative 'kanoah_rspec_formatter/version'
|
4
|
-
require_relative 'kanoah_rspec_formatter/configuration'
|
5
4
|
require_relative 'kanoah_rspec_formatter/rspec_steps'
|
6
5
|
require_relative 'kanoah_rspec_formatter/adapter'
|
7
6
|
require_relative 'kanoah_result_formatter'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kanoah_rspec_formatter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Automation Wizards
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -72,7 +72,6 @@ files:
|
|
72
72
|
- lib/kanoah_result_formatter.rb
|
73
73
|
- lib/kanoah_rspec_formatter.rb
|
74
74
|
- lib/kanoah_rspec_formatter/adapter.rb
|
75
|
-
- lib/kanoah_rspec_formatter/configuration.rb
|
76
75
|
- lib/kanoah_rspec_formatter/rspec_steps.rb
|
77
76
|
- lib/kanoah_rspec_formatter/version.rb
|
78
77
|
homepage: https://loblawdigital.ca
|
@@ -1,25 +0,0 @@
|
|
1
|
-
module KanoahRSpecFormatter
|
2
|
-
module Config
|
3
|
-
class << self
|
4
|
-
attr_accessor :config
|
5
|
-
end
|
6
|
-
|
7
|
-
def self.configure
|
8
|
-
self.config ||= Configuration.new
|
9
|
-
yield(config)
|
10
|
-
end
|
11
|
-
|
12
|
-
class Configuration
|
13
|
-
attr_accessor :base_url, :test_run_id, :environment, :username, :password, :project_id
|
14
|
-
|
15
|
-
def initialize
|
16
|
-
@base_url = nil
|
17
|
-
@test_run_id = nil
|
18
|
-
@project_id = nil
|
19
|
-
@environment = nil
|
20
|
-
@username = nil
|
21
|
-
@password = nil
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|