-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #48 from eficode/feat/rf-metadata-atest
Add acceptance tests for RF metadata coming from handlers
- Loading branch information
Showing
3 changed files
with
60 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
*** Settings *** | ||
Library oxygen.OxygenLibrary | ||
Metadata RF suite This metadata comes from the suite file itself | ||
|
||
*** Test Cases *** | ||
Metadata returned by handler should be visible | ||
[Documentation] This test is replaced with fix results that have metadata in them | ||
Run Metadata Dummy Handler doesentmatter | ||
|
21 changes: 21 additions & 0 deletions
21
tests/resources/my_dummy_handlers/dummy_handler_metadata.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
from oxygen import BaseHandler | ||
|
||
class MyDummyMetadataHandler(BaseHandler): | ||
def run_metadata_dummy_handler(self, result_file): | ||
return result_file | ||
|
||
def parse_results(self, result_file): | ||
return { | ||
'name': 'Minimal Suite', | ||
'metadata': { | ||
'Main-level metadata': 'This should come *from handler*' | ||
}, | ||
'suites': [{ | ||
'name': 'Minimal Subsuite', | ||
'metadata': { 'Sub-level metadata': '_Inner_ metadata' }, | ||
'tests': [{ | ||
'name': 'Minimal TC', | ||
'keywords': [{ 'name': 'someKeyword', 'pass': True }] | ||
}] | ||
}] | ||
} |