-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added version bump * Fixed error handling Reckoner now raises an error to the user and is handled gracefully by click. * Added error handling to click plot command to expect reckoner exceptions * Fixed inheritance of reckoner exceptions * Added tests around this new behavior * Added testing to assure if at least a single chart in --only is correct, the run still succeeds but warns you at the end of missing charts * Adjustments Fixed the logging behavior of hook events: Now hooks will alwyas show the output they have (stderr and/or stdout). * Fixed bug with incorrect impl for python2 for truthy class objects * Added tests to assure we're logging errors on failed exit codes * Added tests to assure we're catching uncaught exceptions so click can handle them * changelog * Fixing output visibility * Added tests around not firing webhooks * Added text and fixed sig * Added Issue 60 * Assertions for hooks running from working dir of course.yml * Asserts for hooks being string or lists * Renaming 'file' to not override the default behavior of 'file' in python * Added changelog * More testing of error raising * The dirname() was returning "" empty white space which was causing subprocess to try and cd to "" dir which cannot exist. This may not have been caught if ./ was used in testing * Added tests Testing to assure that this contract doesn't break in the future. Assert that course_base_directory never returns an empty string for any valid URL paths * Rearranged a test for better actionability on failures. * Adjusted to ignore tests inclusion for packaging
- Loading branch information
Showing
18 changed files
with
423 additions
and
79 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
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
Empty file.
22 changes: 22 additions & 0 deletions
22
reckoner/command_line_caller/tests/test_command_line_caller.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,22 @@ | ||
import unittest | ||
from reckoner.command_line_caller import Response | ||
|
||
|
||
class TestResponse(unittest.TestCase): | ||
def test_properties(self): | ||
required_attrs = { | ||
'stdout': 'stdout value', | ||
'stderr': 'stderr value', | ||
'exitcode': 0, | ||
'command_string': 'command -that -ran', | ||
} | ||
response = Response(**required_attrs) | ||
for attr, value in required_attrs.items(): | ||
self.assertEqual(getattr(response, attr), value) | ||
|
||
def test_bool(self): | ||
response = Response('', '', 127, '') | ||
self.assertFalse(response, "Any response where exitcode is not 0 should return false") | ||
|
||
response = Response('', '', 0, '') | ||
self.assertTrue(response, "All responses with exitcode 0 should return True") |
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
Oops, something went wrong.