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: resource state tests #9307

Merged
merged 2 commits into from May 10, 2022

Conversation

pasha-codefresh
Copy link
Member

Resource state tests inside app.cmd

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

codecov bot commented May 5, 2022

Codecov Report

Merging #9307 (e1263ad) into master (194f090) will increase coverage by 0.06%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #9307      +/-   ##
==========================================
+ Coverage   46.06%   46.12%   +0.06%     
==========================================
  Files         217      217              
  Lines       25908    25908              
==========================================
+ Hits        11934    11951      +17     
+ Misses      12317    12299      -18     
- Partials     1657     1658       +1     
Impacted Files Coverage Δ
cmd/argocd/commands/app.go 19.44% <ø> (+1.45%) ⬆️
applicationset/services/scm_provider/github.go 75.29% <0.00%> (-5.89%) ⬇️
util/settings/settings.go 48.10% <0.00%> (ø)

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 194f090...e1263ad. Read the comment docs.

Copy link
Collaborator

@crenshaw-dev crenshaw-dev left a comment

Choose a reason for hiding this comment

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

Just nitpicks. :-)

}

key := rst.Key()
assert.Equal(t, key, "group/kind/namespace/name")
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think the assertion is backwards here. shouldn't the expected value be first?

assert.False(t, updated)
}

func TestCheckResourceStatus(t *testing.T) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not required but would be nice: could you add a docstring to the checkResourceStatus function? It's not immediately obvious what it's meant to do.

Signed-off-by: pashavictorovich <pavel@codefresh.io>
@crenshaw-dev crenshaw-dev merged commit 8cc8a7f into argoproj:master May 10, 2022
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.

None yet

3 participants