mirror of
https://gitea.invidious.io/iv-org/shard-spectator.git
synced 2024-08-15 00:53:35 +00:00
Use standard status text
This commit is contained in:
parent
ff20fbe232
commit
50929c6666
4 changed files with 19 additions and 1 deletions
|
@ -10,6 +10,11 @@ module Spectator::Formatting
|
||||||
def initialize(@result : FailedResult)
|
def initialize(@result : FailedResult)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Status string specific to the result type.
|
||||||
|
private def status
|
||||||
|
"FAIL"
|
||||||
|
end
|
||||||
|
|
||||||
# Adds the failed expectations to the XML block.
|
# Adds the failed expectations to the XML block.
|
||||||
private def content(xml)
|
private def content(xml)
|
||||||
super
|
super
|
||||||
|
|
|
@ -12,7 +12,7 @@ module Spectator::Formatting
|
||||||
private def attributes
|
private def attributes
|
||||||
{
|
{
|
||||||
name: result.example,
|
name: result.example,
|
||||||
status: result,
|
status: status,
|
||||||
classname: classname,
|
classname: classname,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
@ -20,6 +20,9 @@ module Spectator::Formatting
|
||||||
# Result to pull values from.
|
# Result to pull values from.
|
||||||
private abstract def result
|
private abstract def result
|
||||||
|
|
||||||
|
# Status string specific to the result type.
|
||||||
|
private abstract def status : String
|
||||||
|
|
||||||
# Adds additional content to the "testcase" XML block.
|
# Adds additional content to the "testcase" XML block.
|
||||||
# Override this to add more content.
|
# Override this to add more content.
|
||||||
private def content(xml)
|
private def content(xml)
|
||||||
|
|
|
@ -10,6 +10,11 @@ module Spectator::Formatting
|
||||||
def initialize(@result : PendingResult)
|
def initialize(@result : PendingResult)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Status string specific to the result type.
|
||||||
|
private def status
|
||||||
|
"TODO"
|
||||||
|
end
|
||||||
|
|
||||||
# Adds the skipped tag to the XML block.
|
# Adds the skipped tag to the XML block.
|
||||||
private def content(xml)
|
private def content(xml)
|
||||||
super
|
super
|
||||||
|
|
|
@ -7,5 +7,10 @@ module Spectator::Formatting
|
||||||
# Creates the JUnit test case.
|
# Creates the JUnit test case.
|
||||||
def initialize(@result : SuccessfulResult)
|
def initialize(@result : SuccessfulResult)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Status string specific to the result type.
|
||||||
|
private def status
|
||||||
|
"PASS"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue