perfecto-reporting 1.0.0 → 1.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/perfecto-reporting/client/PerfectoReportiumClient.rb +100 -110
- data/lib/perfecto-reporting/client/ReportiumClientFactory.rb +9 -0
- data/lib/perfecto-reporting/client/constants.rb +5 -0
- data/lib/perfecto-reporting/exceptions/ReportiumException.rb +11 -11
- data/lib/perfecto-reporting/model/Job.rb +15 -15
- data/lib/perfecto-reporting/model/PerfectoExecutionContext.rb +95 -95
- data/lib/perfecto-reporting/model/Project.rb +19 -17
- data/lib/perfecto-reporting/test/TestContext.rb +13 -13
- data/lib/perfecto-reporting/test/result/TestResult.rb +13 -13
- data/lib/perfecto-reporting/test/result/TestResultFactory.rb +25 -25
- data/lib/perfecto-reporting/test/result/TestResultFailure.rb +35 -31
- data/lib/perfecto-reporting/test/result/TestResultSuccess.rb +17 -17
- data/lib/perfecto-reporting/version.rb +7 -7
- data/lib/perfecto-reporting.rb +19 -18
- metadata +23 -21
- checksums.yaml +0 -7
@@ -1,111 +1,101 @@
|
|
1
|
-
|
2
|
-
require_relative '../
|
3
|
-
require_relative '
|
4
|
-
|
5
|
-
# PerfectoReportiumClient
|
6
|
-
class PerfectoReportiumClient
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
#
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
unless @perfectoExecutionContext.
|
29
|
-
params['
|
30
|
-
params['
|
31
|
-
end
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
#
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
#
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
end
|
102
|
-
|
103
|
-
return url
|
104
|
-
end
|
105
|
-
|
106
|
-
def executeScript(script, params)
|
107
|
-
webdriver = @perfectoExecutionContext.webdriver
|
108
|
-
return webdriver.execute_script(script, params)
|
109
|
-
end
|
110
|
-
|
1
|
+
require_relative '../model/PerfectoExecutionContext'
|
2
|
+
require_relative '../exceptions/ReportiumException'
|
3
|
+
require_relative 'constants'
|
4
|
+
|
5
|
+
# PerfectoReportiumClient
|
6
|
+
class PerfectoReportiumClient
|
7
|
+
|
8
|
+
attr_accessor :perfectoExecutionContext
|
9
|
+
|
10
|
+
def initialize(perfectoExecutionContext)
|
11
|
+
@perfectoExecutionContext = perfectoExecutionContext
|
12
|
+
end
|
13
|
+
|
14
|
+
# creates a new test execution
|
15
|
+
#
|
16
|
+
# name - test name
|
17
|
+
# context - test context instance
|
18
|
+
#
|
19
|
+
# returns - id of created test
|
20
|
+
def testStart(name, context)
|
21
|
+
params = {}
|
22
|
+
|
23
|
+
unless @perfectoExecutionContext.job.nil?
|
24
|
+
params['jobName'] = @perfectoExecutionContext.job.name
|
25
|
+
params['jobNumber'] = @perfectoExecutionContext.job.number
|
26
|
+
end
|
27
|
+
|
28
|
+
unless @perfectoExecutionContext.project.nil?
|
29
|
+
params['projectName'] = @perfectoExecutionContext.job.name
|
30
|
+
params['projectVersion'] = @perfectoExecutionContext.project.version
|
31
|
+
end
|
32
|
+
|
33
|
+
params['name'] = name
|
34
|
+
params['tags'] = @perfectoExecutionContext.contextTags + context.testExecutionTags
|
35
|
+
|
36
|
+
executeScript($START_TEST_COMMAND, params)
|
37
|
+
end
|
38
|
+
|
39
|
+
|
40
|
+
|
41
|
+
# logging a logical test step.
|
42
|
+
#
|
43
|
+
# description - step description, will be presented on reporting ui.
|
44
|
+
#
|
45
|
+
# returns - id of created step
|
46
|
+
#
|
47
|
+
# e.g. 'click on next button'
|
48
|
+
def testStep(description)
|
49
|
+
executeScript($TEST_STEP_COMMAND, {:name => description})
|
50
|
+
end
|
51
|
+
|
52
|
+
|
53
|
+
# Indicates that the test has stopped and its execution status.
|
54
|
+
#
|
55
|
+
# testResult - testResult instance
|
56
|
+
#
|
57
|
+
# returns - false if the method failed due to existing conditions such as a previous call to testStart that failed,
|
58
|
+
# otherwise return true
|
59
|
+
def testStop(testResult)
|
60
|
+
|
61
|
+
params = {
|
62
|
+
:success => testResult.isSuccessful
|
63
|
+
}
|
64
|
+
|
65
|
+
if !testResult.isSuccessful
|
66
|
+
params['failureDescription'] = testResult.message
|
67
|
+
end
|
68
|
+
|
69
|
+
executeScript($END_TEST_COMMAND, params)
|
70
|
+
return true
|
71
|
+
end
|
72
|
+
|
73
|
+
|
74
|
+
# Returns the URL to the created online report in Perfecto's reporting solution.
|
75
|
+
#
|
76
|
+
# name - test name
|
77
|
+
# The report is based on all tests that match the current execution context, and is not
|
78
|
+
# limited to a single functional test execution.
|
79
|
+
#
|
80
|
+
# returns - URL to the created online report
|
81
|
+
#
|
82
|
+
# raise exception if driver has no capabilities variable
|
83
|
+
def getReportUrl()
|
84
|
+
url = nil
|
85
|
+
webdriver = @perfectoExecutionContext.webdriver
|
86
|
+
|
87
|
+
begin
|
88
|
+
url = webdriver.capabilities['testGridReportUrl']
|
89
|
+
rescue Exception => e
|
90
|
+
raise ReportiumException.new e.message
|
91
|
+
end
|
92
|
+
|
93
|
+
return url
|
94
|
+
end
|
95
|
+
|
96
|
+
def executeScript(script, params)
|
97
|
+
webdriver = @perfectoExecutionContext.webdriver
|
98
|
+
return webdriver.execute_script(script, params)
|
99
|
+
end
|
100
|
+
|
111
101
|
end
|
@@ -1,12 +1,12 @@
|
|
1
|
-
|
2
|
-
# Instance denoting customized reporting exception
|
3
|
-
class ReportiumException < StandardError
|
4
|
-
|
5
|
-
# Create new instance
|
6
|
-
#
|
7
|
-
# msg - new message to be attached to the exception
|
8
|
-
def initialize msg
|
9
|
-
super(msg)
|
10
|
-
end
|
11
|
-
|
1
|
+
|
2
|
+
# Instance denoting customized reporting exception
|
3
|
+
class ReportiumException < StandardError
|
4
|
+
|
5
|
+
# Create new instance
|
6
|
+
#
|
7
|
+
# msg - new message to be attached to the exception
|
8
|
+
def initialize msg
|
9
|
+
super(msg)
|
10
|
+
end
|
11
|
+
|
12
12
|
end
|
@@ -1,16 +1,16 @@
|
|
1
|
-
|
2
|
-
# Job
|
3
|
-
# Defines a job which runs the test / group of tests
|
4
|
-
#
|
5
|
-
# This can be used in order to locate specific job in reporting ui
|
6
|
-
class Job
|
7
|
-
|
8
|
-
attr_accessor :name, :number
|
9
|
-
|
10
|
-
# initialize a new job instance
|
11
|
-
def initialize name, number
|
12
|
-
@name = name
|
13
|
-
@number = number
|
14
|
-
end
|
15
|
-
|
1
|
+
|
2
|
+
# Job
|
3
|
+
# Defines a job which runs the test / group of tests
|
4
|
+
#
|
5
|
+
# This can be used in order to locate specific job in reporting ui
|
6
|
+
class Job
|
7
|
+
|
8
|
+
attr_accessor :name, :number
|
9
|
+
|
10
|
+
# initialize a new job instance
|
11
|
+
def initialize name, number
|
12
|
+
@name = name
|
13
|
+
@number = number
|
14
|
+
end
|
15
|
+
|
16
16
|
end
|
@@ -1,95 +1,95 @@
|
|
1
|
-
require_relative '../exceptions/ReportiumException'
|
2
|
-
|
3
|
-
# PerfectoExecutionContext
|
4
|
-
#
|
5
|
-
# This class define execution for MCM-based clients.
|
6
|
-
#
|
7
|
-
# Creating instance of this class possible only with PerfectoExecutionContextBuilder instance.
|
8
|
-
class PerfectoExecutionContext
|
9
|
-
|
10
|
-
attr_accessor :job, :project, :webdriver, :contextTags
|
11
|
-
|
12
|
-
# create new instance
|
13
|
-
#
|
14
|
-
# perfectoExecutionContextBuilder -
|
15
|
-
# raise ReportiumException if driver not given.
|
16
|
-
def initialize (perfectoExecutionContextBuilder)
|
17
|
-
|
18
|
-
# execution is not possible without webdriver.
|
19
|
-
if perfectoExecutionContextBuilder.webdriver.nil?
|
20
|
-
raise ReportiumException.new('Missing required webdriver argument.')
|
21
|
-
end
|
22
|
-
|
23
|
-
@job = perfectoExecutionContextBuilder.job
|
24
|
-
@project = perfectoExecutionContextBuilder.project
|
25
|
-
@webdriver = perfectoExecutionContextBuilder.webdriver
|
26
|
-
@contextTags = perfectoExecutionContextBuilder.contextTags
|
27
|
-
|
28
|
-
end
|
29
|
-
|
30
|
-
# PerfectoExecutionContext
|
31
|
-
#
|
32
|
-
# This class used to create PerfectoExecutionContext instance
|
33
|
-
#
|
34
|
-
# example:
|
35
|
-
# perfectoExecutionContext::perfectoExecutionContextBuilder
|
36
|
-
# .withJob("job name" , job number )
|
37
|
-
# .withProject("project name" , project version)
|
38
|
-
# .withWebDriver(driver)
|
39
|
-
# .build()
|
40
|
-
class PerfectoExecutionContextBuilder
|
41
|
-
|
42
|
-
@@job = nil
|
43
|
-
@@project = nil
|
44
|
-
@@webdriver = nil
|
45
|
-
@@contextTags = nil
|
46
|
-
|
47
|
-
# define a job
|
48
|
-
def self.withJob job
|
49
|
-
@@job = job
|
50
|
-
return self
|
51
|
-
end
|
52
|
-
|
53
|
-
# define a project
|
54
|
-
def self.withProject project
|
55
|
-
@@project = project
|
56
|
-
return self
|
57
|
-
end
|
58
|
-
|
59
|
-
# define webdriver
|
60
|
-
def self.withWebDriver webdriver
|
61
|
-
@@webdriver = webdriver
|
62
|
-
return self
|
63
|
-
end
|
64
|
-
|
65
|
-
# define contextTags
|
66
|
-
def self.withContextTags *args
|
67
|
-
@@contextTags = args
|
68
|
-
return self
|
69
|
-
end
|
70
|
-
|
71
|
-
# building a new builder instance
|
72
|
-
def self.build
|
73
|
-
return self.new
|
74
|
-
end
|
75
|
-
|
76
|
-
def job
|
77
|
-
@@job
|
78
|
-
end
|
79
|
-
|
80
|
-
def project
|
81
|
-
@@project
|
82
|
-
end
|
83
|
-
|
84
|
-
def contextTags
|
85
|
-
@@contextTags
|
86
|
-
end
|
87
|
-
|
88
|
-
def webdriver
|
89
|
-
@@webdriver
|
90
|
-
end
|
91
|
-
|
92
|
-
end
|
93
|
-
|
94
|
-
end
|
95
|
-
|
1
|
+
require_relative '../exceptions/ReportiumException'
|
2
|
+
|
3
|
+
# PerfectoExecutionContext
|
4
|
+
#
|
5
|
+
# This class define execution for MCM-based clients.
|
6
|
+
#
|
7
|
+
# Creating instance of this class possible only with PerfectoExecutionContextBuilder instance.
|
8
|
+
class PerfectoExecutionContext
|
9
|
+
|
10
|
+
attr_accessor :job, :project, :webdriver, :contextTags
|
11
|
+
|
12
|
+
# create new instance
|
13
|
+
#
|
14
|
+
# perfectoExecutionContextBuilder -
|
15
|
+
# raise ReportiumException if driver not given.
|
16
|
+
def initialize (perfectoExecutionContextBuilder)
|
17
|
+
|
18
|
+
# execution is not possible without webdriver.
|
19
|
+
if perfectoExecutionContextBuilder.webdriver.nil?
|
20
|
+
raise ReportiumException.new('Missing required webdriver argument.')
|
21
|
+
end
|
22
|
+
|
23
|
+
@job = perfectoExecutionContextBuilder.job
|
24
|
+
@project = perfectoExecutionContextBuilder.project
|
25
|
+
@webdriver = perfectoExecutionContextBuilder.webdriver
|
26
|
+
@contextTags = perfectoExecutionContextBuilder.contextTags
|
27
|
+
|
28
|
+
end
|
29
|
+
|
30
|
+
# PerfectoExecutionContext
|
31
|
+
#
|
32
|
+
# This class used to create PerfectoExecutionContext instance
|
33
|
+
#
|
34
|
+
# example:
|
35
|
+
# perfectoExecutionContext::perfectoExecutionContextBuilder
|
36
|
+
# .withJob("job name" , job number )
|
37
|
+
# .withProject("project name" , project version)
|
38
|
+
# .withWebDriver(driver)
|
39
|
+
# .build()
|
40
|
+
class PerfectoExecutionContextBuilder
|
41
|
+
|
42
|
+
@@job = nil
|
43
|
+
@@project = nil
|
44
|
+
@@webdriver = nil
|
45
|
+
@@contextTags = nil
|
46
|
+
|
47
|
+
# define a job
|
48
|
+
def self.withJob job
|
49
|
+
@@job = job
|
50
|
+
return self
|
51
|
+
end
|
52
|
+
|
53
|
+
# define a project
|
54
|
+
def self.withProject project
|
55
|
+
@@project = project
|
56
|
+
return self
|
57
|
+
end
|
58
|
+
|
59
|
+
# define webdriver
|
60
|
+
def self.withWebDriver webdriver
|
61
|
+
@@webdriver = webdriver
|
62
|
+
return self
|
63
|
+
end
|
64
|
+
|
65
|
+
# define contextTags
|
66
|
+
def self.withContextTags *args
|
67
|
+
@@contextTags = args
|
68
|
+
return self
|
69
|
+
end
|
70
|
+
|
71
|
+
# building a new builder instance
|
72
|
+
def self.build
|
73
|
+
return self.new
|
74
|
+
end
|
75
|
+
|
76
|
+
def job
|
77
|
+
@@job
|
78
|
+
end
|
79
|
+
|
80
|
+
def project
|
81
|
+
@@project
|
82
|
+
end
|
83
|
+
|
84
|
+
def contextTags
|
85
|
+
@@contextTags
|
86
|
+
end
|
87
|
+
|
88
|
+
def webdriver
|
89
|
+
@@webdriver
|
90
|
+
end
|
91
|
+
|
92
|
+
end # end PerfectoExecutionContextBuilder
|
93
|
+
|
94
|
+
end
|
95
|
+
|
@@ -1,18 +1,20 @@
|
|
1
|
-
# Project
|
2
|
-
#
|
3
|
-
#
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
#
|
12
|
-
#
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
1
|
+
# Project
|
2
|
+
#
|
3
|
+
# Tests can be filtered by project they belong to.
|
4
|
+
#
|
5
|
+
# Usage:
|
6
|
+
# Project.new projectName, projectVersion
|
7
|
+
class Project
|
8
|
+
|
9
|
+
attr_accessor :name, :version
|
10
|
+
|
11
|
+
# initialize new project instance
|
12
|
+
#
|
13
|
+
# name - the new project's name
|
14
|
+
# version - the project's version
|
15
|
+
def initialize name, version
|
16
|
+
@name = name
|
17
|
+
@version = version
|
18
|
+
end
|
19
|
+
|
18
20
|
end
|
@@ -1,14 +1,14 @@
|
|
1
|
-
# TestContext
|
2
|
-
#
|
3
|
-
# TestContext tags will be presented in reporting ui.
|
4
|
-
# This tags attached to each test execution.
|
5
|
-
class TestContext
|
6
|
-
|
7
|
-
attr_accessor :testExecutionTags
|
8
|
-
|
9
|
-
# Create TestContext instance
|
10
|
-
def initialize *args
|
11
|
-
@testExecutionTags = args
|
12
|
-
end
|
13
|
-
|
1
|
+
# TestContext
|
2
|
+
#
|
3
|
+
# TestContext tags will be presented in reporting ui.
|
4
|
+
# This tags attached to each test execution.
|
5
|
+
class TestContext
|
6
|
+
|
7
|
+
attr_accessor :testExecutionTags
|
8
|
+
|
9
|
+
# Create TestContext instance
|
10
|
+
def initialize *args
|
11
|
+
@testExecutionTags = args
|
12
|
+
end
|
13
|
+
|
14
14
|
end
|
@@ -1,14 +1,14 @@
|
|
1
|
-
# Test result
|
2
|
-
#
|
3
|
-
# This class define a basic TestResult instance structure
|
4
|
-
class TestResult
|
5
|
-
|
6
|
-
def isSuccessful
|
7
|
-
raise 'Not Implemented Method'
|
8
|
-
end
|
9
|
-
|
10
|
-
def status
|
11
|
-
raise 'Not Implemented Method'
|
12
|
-
end
|
13
|
-
|
1
|
+
# Test result
|
2
|
+
#
|
3
|
+
# This class define a basic TestResult instance structure
|
4
|
+
class TestResult
|
5
|
+
|
6
|
+
def isSuccessful
|
7
|
+
raise 'Not Implemented Method'
|
8
|
+
end
|
9
|
+
|
10
|
+
def status
|
11
|
+
raise 'Not Implemented Method'
|
12
|
+
end
|
13
|
+
|
14
14
|
end
|
@@ -1,26 +1,26 @@
|
|
1
|
-
require_relative 'TestResultSuccess'
|
2
|
-
require_relative 'TestResultFailure'
|
3
|
-
|
4
|
-
# TestResultFactory
|
5
|
-
#
|
6
|
-
# Generates a new test result instance.
|
7
|
-
class TestResultFactory
|
8
|
-
|
9
|
-
# create a successful test execution result
|
10
|
-
#
|
11
|
-
# return - instance denoting a successful test execution
|
12
|
-
def self.createSuccess
|
13
|
-
return TestResultSuccess.new
|
14
|
-
end
|
15
|
-
|
16
|
-
# Creates a failed test execution result
|
17
|
-
#
|
18
|
-
# reason - string representation of the reason for the test failure
|
19
|
-
# error - the exception caused the failure
|
20
|
-
#
|
21
|
-
# return - instance denoting a failed test execution
|
22
|
-
def self.createFailure reason, error
|
23
|
-
return TestResultFailure.new(reason, error)
|
24
|
-
end
|
25
|
-
|
1
|
+
require_relative 'TestResultSuccess'
|
2
|
+
require_relative 'TestResultFailure'
|
3
|
+
|
4
|
+
# TestResultFactory
|
5
|
+
#
|
6
|
+
# Generates a new test result instance.
|
7
|
+
class TestResultFactory
|
8
|
+
|
9
|
+
# create a successful test execution result
|
10
|
+
#
|
11
|
+
# return - instance denoting a successful test execution
|
12
|
+
def self.createSuccess
|
13
|
+
return TestResultSuccess.new
|
14
|
+
end
|
15
|
+
|
16
|
+
# Creates a failed test execution result
|
17
|
+
#
|
18
|
+
# reason - string representation of the reason for the test failure
|
19
|
+
# error - the exception caused the failure
|
20
|
+
#
|
21
|
+
# return - instance denoting a failed test execution
|
22
|
+
def self.createFailure reason, error
|
23
|
+
return TestResultFailure.new(reason, error)
|
24
|
+
end
|
25
|
+
|
26
26
|
end
|
@@ -1,32 +1,36 @@
|
|
1
|
-
require_relative 'TestResult'
|
2
|
-
|
3
|
-
# TestResultFailure
|
4
|
-
#
|
5
|
-
# Define a failure test result.
|
6
|
-
class TestResultFailure < TestResult
|
7
|
-
|
8
|
-
attr_accessor :message
|
9
|
-
|
10
|
-
@@
|
11
|
-
|
12
|
-
# Create a new instance
|
13
|
-
#
|
14
|
-
# reason - string representation of the failure reason
|
15
|
-
# error - exception caused to the failure
|
16
|
-
def initialize(reason, error)
|
17
|
-
if error.is_a? Exception
|
18
|
-
@message = reason + '. Stack Trace:' + error.backtrace.to_s
|
19
|
-
else
|
20
|
-
@message = reason
|
21
|
-
end
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
end
|
27
|
-
|
28
|
-
def
|
29
|
-
|
30
|
-
end
|
31
|
-
|
1
|
+
require_relative 'TestResult'
|
2
|
+
|
3
|
+
# TestResultFailure
|
4
|
+
#
|
5
|
+
# Define a failure test result.
|
6
|
+
class TestResultFailure < TestResult
|
7
|
+
|
8
|
+
attr_accessor :message
|
9
|
+
|
10
|
+
@@STATUS = 'FAILED'
|
11
|
+
|
12
|
+
# Create a new instance
|
13
|
+
#
|
14
|
+
# reason - string representation of the failure reason
|
15
|
+
# error - exception caused to the failure
|
16
|
+
def initialize(reason, error)
|
17
|
+
if error.is_a? Exception
|
18
|
+
@message = reason + '. Stack Trace:' + error.backtrace.to_s
|
19
|
+
else
|
20
|
+
@message = reason
|
21
|
+
end
|
22
|
+
## Validate that the reason + error stacktrace are not longer then 4096 charcters
|
23
|
+
if @message.length > 4096
|
24
|
+
@message = @message[0,4096]
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
def isSuccessful
|
29
|
+
return false
|
30
|
+
end
|
31
|
+
|
32
|
+
def status
|
33
|
+
@@STATUS
|
34
|
+
end
|
35
|
+
|
32
36
|
end
|
@@ -1,18 +1,18 @@
|
|
1
|
-
require_relative 'TestResult'
|
2
|
-
|
3
|
-
# TestResultSuccess
|
4
|
-
#
|
5
|
-
# Define a successful test result
|
6
|
-
class TestResultSuccess < TestResult
|
7
|
-
|
8
|
-
@@
|
9
|
-
|
10
|
-
def isSuccessful
|
11
|
-
return true
|
12
|
-
end
|
13
|
-
|
14
|
-
def status
|
15
|
-
@@
|
16
|
-
end
|
17
|
-
|
1
|
+
require_relative 'TestResult'
|
2
|
+
|
3
|
+
# TestResultSuccess
|
4
|
+
#
|
5
|
+
# Define a successful test result
|
6
|
+
class TestResultSuccess < TestResult
|
7
|
+
|
8
|
+
@@STATUS = 'PASSED'
|
9
|
+
|
10
|
+
def isSuccessful
|
11
|
+
return true
|
12
|
+
end
|
13
|
+
|
14
|
+
def status
|
15
|
+
@@STATUS
|
16
|
+
end
|
17
|
+
|
18
18
|
end
|
@@ -1,7 +1,7 @@
|
|
1
|
-
# Modified by Perfecto Mobile Ltd.
|
2
|
-
|
3
|
-
module Reporting
|
4
|
-
module Perfecto
|
5
|
-
VERSION = "1.
|
6
|
-
end
|
7
|
-
end
|
1
|
+
# Modified by Perfecto Mobile Ltd.
|
2
|
+
|
3
|
+
module Reporting
|
4
|
+
module Perfecto
|
5
|
+
VERSION = "1.1.2"
|
6
|
+
end
|
7
|
+
end
|
data/lib/perfecto-reporting.rb
CHANGED
@@ -1,18 +1,19 @@
|
|
1
|
-
# perfecto-reporting Gem
|
2
|
-
#
|
3
|
-
# For more information about the gem read the documentation file.
|
4
|
-
# For support check out our community at : www.community.perfectomobile.com
|
5
|
-
#
|
6
|
-
# MIT License
|
7
|
-
|
8
|
-
# Client classes
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
1
|
+
# perfecto-reporting Gem
|
2
|
+
#
|
3
|
+
# For more information about the gem read the documentation file.
|
4
|
+
# For support check out our community at : www.community.perfectomobile.com
|
5
|
+
#
|
6
|
+
# MIT License
|
7
|
+
|
8
|
+
# Client classes
|
9
|
+
require_relative './perfecto-reporting/client/PerfectoReportiumClient'
|
10
|
+
require_relative './perfecto-reporting/client/ReportiumClientFactory'
|
11
|
+
|
12
|
+
# Model classes
|
13
|
+
require_relative 'perfecto-reporting/model/PerfectoExecutionContext'
|
14
|
+
require_relative 'perfecto-reporting/model/Job'
|
15
|
+
require_relative 'perfecto-reporting/model/Project'
|
16
|
+
|
17
|
+
# Test classes
|
18
|
+
require_relative 'perfecto-reporting/test/TestContext'
|
19
|
+
require_relative 'perfecto-reporting/test/result/TestResultFactory'
|
metadata
CHANGED
@@ -1,75 +1,77 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: perfecto-reporting
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.2
|
5
|
+
prerelease:
|
5
6
|
platform: ruby
|
6
7
|
authors:
|
7
8
|
- perfecto
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date: 2016-
|
12
|
+
date: 2016-12-22 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: selenium-webdriver
|
15
16
|
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
16
18
|
requirements:
|
17
|
-
- -
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: '2.53'
|
20
|
-
- - ">="
|
19
|
+
- - ! '>='
|
21
20
|
- !ruby/object:Gem::Version
|
22
21
|
version: 2.53.0
|
23
22
|
type: :runtime
|
24
23
|
prerelease: false
|
25
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
26
|
requirements:
|
27
|
-
- -
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
version: '2.53'
|
30
|
-
- - ">="
|
27
|
+
- - ! '>='
|
31
28
|
- !ruby/object:Gem::Version
|
32
29
|
version: 2.53.0
|
33
|
-
description:
|
30
|
+
description: ! "Perfecto Reporting is a multiple execution digital report, that enables
|
31
|
+
quick navigation within your latest build execution.\n Get visibility of your test
|
32
|
+
execution status and quickly identify potential problems with an aggregated report."
|
34
33
|
email: daniela@perfectomobile.com
|
35
34
|
executables: []
|
36
35
|
extensions: []
|
37
36
|
extra_rdoc_files: []
|
38
37
|
files:
|
39
38
|
- lib/perfecto-reporting.rb
|
40
|
-
- lib/perfecto-reporting/client/PerfectoReportiumClient.rb
|
41
39
|
- lib/perfecto-reporting/exceptions/ReportiumException.rb
|
40
|
+
- lib/perfecto-reporting/version.rb
|
41
|
+
- lib/perfecto-reporting/model/Project.rb
|
42
42
|
- lib/perfecto-reporting/model/Job.rb
|
43
43
|
- lib/perfecto-reporting/model/PerfectoExecutionContext.rb
|
44
|
-
- lib/perfecto-reporting/
|
44
|
+
- lib/perfecto-reporting/client/PerfectoReportiumClient.rb
|
45
|
+
- lib/perfecto-reporting/client/ReportiumClientFactory.rb
|
46
|
+
- lib/perfecto-reporting/client/constants.rb
|
45
47
|
- lib/perfecto-reporting/test/TestContext.rb
|
46
|
-
- lib/perfecto-reporting/test/result/
|
48
|
+
- lib/perfecto-reporting/test/result/TestResultSuccess.rb
|
47
49
|
- lib/perfecto-reporting/test/result/TestResultFactory.rb
|
50
|
+
- lib/perfecto-reporting/test/result/TestResult.rb
|
48
51
|
- lib/perfecto-reporting/test/result/TestResultFailure.rb
|
49
|
-
- lib/perfecto-reporting/test/result/TestResultSuccess.rb
|
50
|
-
- lib/perfecto-reporting/version.rb
|
51
52
|
homepage: http://rubygems.org/gems/Perfecto-Reporting
|
52
53
|
licenses:
|
53
54
|
- MIT
|
54
|
-
metadata: {}
|
55
55
|
post_install_message:
|
56
56
|
rdoc_options: []
|
57
57
|
require_paths:
|
58
58
|
- lib
|
59
59
|
required_ruby_version: !ruby/object:Gem::Requirement
|
60
|
+
none: false
|
60
61
|
requirements:
|
61
|
-
- -
|
62
|
+
- - ! '>='
|
62
63
|
- !ruby/object:Gem::Version
|
63
64
|
version: '0'
|
64
65
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
66
|
+
none: false
|
65
67
|
requirements:
|
66
|
-
- -
|
68
|
+
- - ! '>='
|
67
69
|
- !ruby/object:Gem::Version
|
68
70
|
version: '0'
|
69
71
|
requirements: []
|
70
72
|
rubyforge_project:
|
71
|
-
rubygems_version:
|
73
|
+
rubygems_version: 1.8.23
|
72
74
|
signing_key:
|
73
|
-
specification_version:
|
75
|
+
specification_version: 3
|
74
76
|
summary: perfecto reporting sdk
|
75
77
|
test_files: []
|
checksums.yaml
DELETED
@@ -1,7 +0,0 @@
|
|
1
|
-
---
|
2
|
-
SHA1:
|
3
|
-
metadata.gz: 4a8d8e76e6f37480eee7f5300238d7b60249d20b
|
4
|
-
data.tar.gz: 7bec1c7b3b3c8f29ad827427d91513e05292ef85
|
5
|
-
SHA512:
|
6
|
-
metadata.gz: 4c711244a1a30c4ed13311ba801c46dca95d8b64453c4b26c344126bf4fd2a0df70a3f5e18964b2137e21d8852b9020328cfefbb8e70b2473a7ee8f93cdebf5e
|
7
|
-
data.tar.gz: 1828afc5cc6990974260f51e4b2584760b6eb01180ffd97626cd0b08ef9e24e7e6452a27f1f639a181e702b6140200255021cc2ee84c9208b20e3971640b817a
|