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

chore: fix imports and unit tests #8857

Merged
merged 4 commits into from
Mar 22, 2022
Merged

Conversation

crenshaw-dev
Copy link
Member

Signed-off-by: Michael Crenshaw michael@crenshaw.dev

Note on DCO:

If the DCO action in the integration test fails, one or more of your commits are not signed off. Please click on the Details link next to the DCO action for instructions on how to resolve this.

Checklist:

  • Either (a) I've created an enhancement proposal and discussed it with the community, (b) this is a bug fix, or (c) this does not need to be in the release notes.
  • The title of the PR states what changed and the related issues number (used for the release note).
  • I've included "Closes [ISSUE #]" or "Fixes [ISSUE #]" in the description to automatically close the associated issue.
  • I've updated both the CLI and UI to expose my feature, or I plan to submit a second PR with them.
  • Does this PR require documentation updates?
  • I've updated documentation as required by this PR.
  • Optional. My organization is added to USERS.md.
  • I have signed off all my commits as required by DCO
  • I have written unit and/or e2e tests for my change. PRs without these are unlikely to be merged.
  • My build is green (troubleshooting builds).

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
@crenshaw-dev crenshaw-dev marked this pull request as ready for review March 22, 2022 18:11
@alexmt
Copy link
Collaborator

alexmt commented Mar 22, 2022

Thank you!

Copy link
Collaborator

@alexmt alexmt left a comment

Choose a reason for hiding this comment

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

LGTM

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
@@ -266,7 +266,7 @@ func TestSetHealth(t *testing.T) {
app := newFakeApp()
deployment := kube.MustToUnstructured(&v1.Deployment{
TypeMeta: metav1.TypeMeta{
APIVersion: "apps/v1beta1",
APIVersion: "apps/v1",
Copy link
Member Author

Choose a reason for hiding this comment

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

idk why this fixes the test, and it worries me a little bit.

Copy link
Member Author

@crenshaw-dev crenshaw-dev Mar 22, 2022

Choose a reason for hiding this comment

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

I found it by inspecting compRes and noticed the sync status said something about "invalid GVK".

@@ -289,7 +289,7 @@ func TestSetHealth(t *testing.T) {

compRes := ctrl.appStateManager.CompareAppState(app, &defaultProj, "", app.Spec.Source, false, false, nil)

assert.Equal(t, compRes.healthStatus.Status, health.HealthStatusHealthy)
assert.Equal(t, health.HealthStatusHealthy, compRes.healthStatus.Status)
Copy link
Member Author

@crenshaw-dev crenshaw-dev Mar 22, 2022

Choose a reason for hiding this comment

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

Order was wrong. It should be expected, actual.

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
@codecov
Copy link

codecov bot commented Mar 22, 2022

Codecov Report

Merging #8857 (b6f95a3) into master (a6c664b) will decrease coverage by 0.02%.
The diff coverage is 18.75%.

@@            Coverage Diff             @@
##           master    #8857      +/-   ##
==========================================
- Coverage   42.87%   42.85%   -0.03%     
==========================================
  Files         186      186              
  Lines       23335    23359      +24     
==========================================
+ Hits        10006    10011       +5     
- Misses      11898    11914      +16     
- Partials     1431     1434       +3     
Impacted Files Coverage Δ
controller/cache/cache.go 20.76% <0.00%> (ø)
pkg/apis/application/v1alpha1/app_project_types.go 51.83% <0.00%> (-0.28%) ⬇️
server/application/application.go 31.37% <7.14%> (-0.19%) ⬇️
controller/appcontroller.go 51.61% <38.46%> (-0.21%) ⬇️

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 af03b29...b6f95a3. Read the comment docs.

@crenshaw-dev crenshaw-dev changed the title chore: fix imports chore: fix imports and unit tests Mar 22, 2022
@alexmt alexmt merged commit b144fbb into argoproj:master Mar 22, 2022
@crenshaw-dev crenshaw-dev deleted the fix-imports branch March 22, 2022 19:58
crenshaw-dev added a commit that referenced this pull request Apr 8, 2022
* proposal: support multiple sources for an Application

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* addressed PR comments

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* update summary

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* feat: move watch params to struct  (#8819)

* add to approvers

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* watch opts move to struct

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* watch opts move to struct

Signed-off-by: pashavictorovich <pavel@codefresh.io>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* Merge pull request from GHSA-2f5v-8r3f-8pww

* fix: application resource APIs must enforce project restrictions

Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>

* Fix unit tests

Signed-off-by: jannfis <jann@mistrust.net>

Co-authored-by: jannfis <jann@mistrust.net>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* chore: fix imports and unit tests (#8857)

* chore: fix imports

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix unit test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: keep changes minimal

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix another test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* feat: operation result and history table tests (#8887)

* add to approvers

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* print tables additional tests

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* move to %q

Signed-off-by: pashavictorovich <pavel@codefresh.io>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* fix: corrected applicationset binary name in manifests (#8954)

Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* Update proposed design to add 'ref' field instead of externalValuesField

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* remove unwanted changes from PR added while rebase

Signed-off-by: ishitasequeira <isequeir@redhat.com>

Co-authored-by: pasha-codefresh <pavel@codefresh.io>
Co-authored-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Co-authored-by: jannfis <jann@mistrust.net>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: rishabh625 <43094970+rishabh625@users.noreply.github.com>
ashutosh16 pushed a commit to ashutosh16/argo-cd that referenced this pull request Apr 9, 2022
* proposal: support multiple sources for an Application

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* addressed PR comments

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* update summary

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* feat: move watch params to struct  (argoproj#8819)

* add to approvers

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* watch opts move to struct

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* watch opts move to struct

Signed-off-by: pashavictorovich <pavel@codefresh.io>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* Merge pull request from GHSA-2f5v-8r3f-8pww

* fix: application resource APIs must enforce project restrictions

Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>

* Fix unit tests

Signed-off-by: jannfis <jann@mistrust.net>

Co-authored-by: jannfis <jann@mistrust.net>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* chore: fix imports and unit tests (argoproj#8857)

* chore: fix imports

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix unit test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: keep changes minimal

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix another test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* feat: operation result and history table tests (argoproj#8887)

* add to approvers

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* print tables additional tests

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* move to %q

Signed-off-by: pashavictorovich <pavel@codefresh.io>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* fix: corrected applicationset binary name in manifests (argoproj#8954)

Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* Update proposed design to add 'ref' field instead of externalValuesField

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* remove unwanted changes from PR added while rebase

Signed-off-by: ishitasequeira <isequeir@redhat.com>

Co-authored-by: pasha-codefresh <pavel@codefresh.io>
Co-authored-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Co-authored-by: jannfis <jann@mistrust.net>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: rishabh625 <43094970+rishabh625@users.noreply.github.com>
Signed-off-by: asingh51 <Ashutosh_Singh@intuit.com>
wojtekidd pushed a commit to wojtekidd/argo-cd that referenced this pull request Apr 25, 2022
* chore: fix imports

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix unit test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: keep changes minimal

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix another test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: wojtekidd <wojtek.cichon@protonmail.com>
wojtekidd pushed a commit to wojtekidd/argo-cd that referenced this pull request Apr 25, 2022
* proposal: support multiple sources for an Application

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* addressed PR comments

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* update summary

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* feat: move watch params to struct  (argoproj#8819)

* add to approvers

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* watch opts move to struct

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* watch opts move to struct

Signed-off-by: pashavictorovich <pavel@codefresh.io>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* Merge pull request from GHSA-2f5v-8r3f-8pww

* fix: application resource APIs must enforce project restrictions

Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>

* Fix unit tests

Signed-off-by: jannfis <jann@mistrust.net>

Co-authored-by: jannfis <jann@mistrust.net>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* chore: fix imports and unit tests (argoproj#8857)

* chore: fix imports

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix unit test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: keep changes minimal

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>

* chore: fix another test

Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* feat: operation result and history table tests (argoproj#8887)

* add to approvers

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* print tables additional tests

Signed-off-by: pashavictorovich <pavel@codefresh.io>

* move to %q

Signed-off-by: pashavictorovich <pavel@codefresh.io>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* fix: corrected applicationset binary name in manifests (argoproj#8954)

Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
Signed-off-by: ishitasequeira <isequeir@redhat.com>

* Update proposed design to add 'ref' field instead of externalValuesField

Signed-off-by: ishitasequeira <isequeir@redhat.com>

* remove unwanted changes from PR added while rebase

Signed-off-by: ishitasequeira <isequeir@redhat.com>

Co-authored-by: pasha-codefresh <pavel@codefresh.io>
Co-authored-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Co-authored-by: jannfis <jann@mistrust.net>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: rishabh625 <43094970+rishabh625@users.noreply.github.com>
Signed-off-by: wojtekidd <wojtek.cichon@protonmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants