-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add unit tests #131
Add unit tests #131
Conversation
8f4db04
to
0cbbe69
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work @vjeffrey
@@ -15,15 +15,16 @@ def report | |||
interval_enabled = node['audit']['interval']['enabled'] | |||
interval_time = node['audit']['interval']['time'] | |||
report_file = node['audit']['output'] | |||
test_array = node['audit']['profiles'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is profiles
maybe a better name? I was thinking about an array of single tests first
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup! 👍
@@ -20,6 +20,9 @@ | |||
require 'spec_helper' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may should rename the spec to visibility_spec.rb
. Do we intent to add more specs for other reporters?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup, i'll move everything to its own spot
0cbbe69
to
1d8dbe8
Compare
require_relative '../../../libraries/collector_classes' | ||
|
||
# TODO: can't get this to work: `# ./libraries/collector_classes.rb:251:in `node_info'` | ||
# need to figure out how to mock the run context |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:( can't figure out how to mock the run context..is there another way around this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The solution is the removal of the run context. I'll work on a PR to cover that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thank you!!
Signed-off-by: Victoria Jeffrey <[email protected]>
1d8dbe8
to
ca6cf4d
Compare
This fixes #128 |
This commit adds more testing!
A few of them I couldn't get to work correctly....