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

VCR updates for tests in kubernetes repo #83

Merged
merged 11 commits into from
Jan 29, 2018

Conversation

cben
Copy link
Contributor

@cben cben commented Jan 15, 2018

  • No longer rely on hawkular metrics for example of volumes.
    Defined PVs, PVCs (successfully bound and pending), and referenced PVC in pod.
    Recorded without --metrics => minishift used ~2GB RAM instead of ~5GB 📉

  • Modify quotas between runs.
    https://bugzilla.redhat.com/show_bug.cgi?id=1504560

@miq-bot add-label test, gaprindashvili/yes

@zeari @yaacov @moolitayer please review (recommend by commits), together with ManageIQ/manageiq-providers-kubernetes#216

Copy link
Member

@yaacov yaacov left a comment

Choose a reason for hiding this comment

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

LGTM

@cben cben changed the title VCR updates for tests in kubernetes repo [WIP] VCR updates for tests in kubernetes repo Jan 16, 2018
@miq-bot miq-bot added the wip label Jan 16, 2018
cben added 3 commits January 24, 2018 15:26
Default sort was by hash, inconvenient.

(and sorted existing .txt so next VCR diff is easy to read)
Add PVs, claim them with PVCs (deterministic 1:1 by label selector), use them in a pod.
@cben cben force-pushed the vcr-for-kubernetes-too branch 3 times, most recently from f401f38 to ef22fe5 Compare January 24, 2018 19:50
@cben cben changed the title [WIP] VCR updates for tests in kubernetes repo VCR updates for tests in kubernetes repo Jan 24, 2018
@cben
Copy link
Contributor Author

cben commented Jan 24, 2018

@zeari @yaacov @moolitayer PTAL, this now has all I want.
Recommend reviewing by commits, the interesting ones are "Add volumes to VCR template, so we can test them in kubernetes repo" and "Quota changes for 1st and 2nd recording".

@miq-bot miq-bot removed the wip label Jan 24, 2018
oc get persistentVolumes --show-labels
echo
echo "== oc get persistentvolumeclaims --all-namespaces --show-kind --show-labels =="
oc get persistentVolumeClaims --all-namespaces --show-labels
Copy link

@moolitayer moolitayer Jan 25, 2018

Choose a reason for hiding this comment

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

We have a diff of --show-kind in the three echo statements above. seems helpful to include, event if we are only showing one object kind at a time.

@cben cben force-pushed the vcr-for-kubernetes-too branch from ef22fe5 to 891e243 Compare January 28, 2018 14:03
@cben
Copy link
Contributor Author

cben commented Jan 28, 2018

Done, PTAL.
Will update k8s PR soon.

@@ -96,12 +114,26 @@ oc label route my-route-2 key-route-label-
oc patch --type=merge template my-template-2 --patch='{"parameters": []}'
oc delete pod my-pod-2

#old_quotas=$("oc describe quota

Choose a reason for hiding this comment

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

should this be here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

thanks, removed

cben added 8 commits January 28, 2018 22:42
- Add a memory quota to test binary suffixes (Mi, Gi).
- Delete all quotas from  my-project-1 before 2nd recording, as test expects.
- Modify quota items for 2nd recording to cover delete, update, no-change.

https://bugzilla.redhat.com/show_bug.cgi?id=1504560
Currently ignored for `oc get images` but let's specify anyway.
var=$(cmd) exit status is cmd exit status.
export ... exit status is always 0.
See https://stackoverflow.com/a/48486983/239657.
…unts

The default PVs are HostPath to /var/lib/minishift/openshift.local.pv/pv0089 etc.
@cben cben force-pushed the vcr-for-kubernetes-too branch from 891e243 to 99ac35b Compare January 28, 2018 20:43
@miq-bot
Copy link
Member

miq-bot commented Jan 28, 2018

Checked commits cben/manageiq-providers-openshift@4dc5914~...99ac35b with ruby 2.3.3, rubocop 0.52.0, haml-lint 0.20.0, and yamllint 1.10.0
4 files checked, 1 offense detected

**

  • 💣 💥 🔥 🚒 - Linter/Yaml - missing config files

Copy link

@moolitayer moolitayer left a comment

Choose a reason for hiding this comment

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

LGTM 👍
@cben good to go?

@cben
Copy link
Contributor Author

cben commented Jan 28, 2018 via email

@moolitayer moolitayer merged commit 542fa53 into ManageIQ:master Jan 29, 2018
@moolitayer moolitayer added this to the Sprint 78 Ending Jan 29, 2018 milestone Jan 29, 2018
@moolitayer moolitayer self-assigned this Jan 29, 2018
cben added a commit to cben/guides that referenced this pull request Jan 29, 2018
simaishi pushed a commit that referenced this pull request Mar 22, 2018
@simaishi
Copy link

Gaprindashvili backport details:

$ git log -1
commit 75da91217e4c4a44f72a3297e65979ca1914bcac
Author: Mooli Tayer <[email protected]>
Date:   Mon Jan 29 07:47:16 2018 +0200

    Merge pull request #83 from cben/vcr-for-kubernetes-too
    
    VCR updates for tests in kubernetes repo
    (cherry picked from commit 542fa531611ea6c100d7382f3b13698d64bd6034)
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1559544

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.

5 participants