Skip to content
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 more test coverage #373

Merged
merged 5 commits into from
Jun 26, 2018
Merged

Conversation

Temikus
Copy link
Member

@Temikus Temikus commented Jun 25, 2018

Further improving coverage:

  • Instance groups
  • Machine types
  • Firewalls
  • a drive by fixes:
  • Firewall sanity check

@Temikus Temikus changed the title Add tests for instance groups Add more test coverage Jun 25, 2018
@Temikus Temikus force-pushed the add_instance_groups_tests branch from c46c867 to 583ad71 Compare June 25, 2018 09:20
Temikus added 2 commits June 25, 2018 20:01
Otherwise we’ll get:
```
TestFirewalls#test_lifecycle:
Google::Apis::ClientError: invalid: Invalid value for field 'resource.allowed[0]': ''. Must specify at least one rule.
```
, which is not very user friendly.
@@ -27,6 +40,10 @@ class Firewall < Fog::Model

def save
requires :identity
q
unless self.allowed || self.denied

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Style/RedundantSelf: Redundant self detected.

@codecov
Copy link

codecov bot commented Jun 26, 2018

Codecov Report

❗ No coverage uploaded for pull request base (master@ba3ff45). Click here to learn what that means.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff            @@
##             master     #373   +/-   ##
=========================================
  Coverage          ?   81.43%           
=========================================
  Files             ?      339           
  Lines             ?     5757           
  Branches          ?        0           
=========================================
  Hits              ?     4688           
  Misses            ?     1069           
  Partials          ?        0
Impacted Files Coverage Δ
lib/fog/compute/google/models/firewall.rb 77.55% <50%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ba3ff45...aadd8b5. Read the comment docs.

@Temikus Temikus force-pushed the add_instance_groups_tests branch from a31a7c3 to aadd8b5 Compare June 26, 2018 01:43
@Temikus
Copy link
Member Author

Temikus commented Jun 26, 2018

All tests pass, merging.

@Temikus Temikus merged commit fa676d0 into fog:master Jun 26, 2018
@Temikus Temikus deleted the add_instance_groups_tests branch March 20, 2019 01:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants