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

Fix: test parameterKey can update an array #172

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

drewwells
Copy link

Description of your changes

ref #171

I have:

  • Read and followed KubeVela's contribution process.
  • Related Docs updated properly. In a new feature or configuration option, an update to the documentation is necessary.
  • Run make reviewable to ensure this PR is ready for review.
  • [/] Added backport release-x.y labels to auto-backport this PR if necessary.

How has this code been tested

It's a test

Special notes for your reviewer

Unit test to enforce issue we found in kubevela/kubevela@0.9.6

Signed-off-by: Drew Wells <dwells@infoblox.com>
@drewwells drewwells changed the title test parameterKey can update an array Fix: test parameterKey can update an array Sep 21, 2023
@codecov
Copy link

codecov bot commented Sep 21, 2023

Codecov Report

Patch coverage has no change and project coverage change: -0.80% ⚠️

Comparison is base (3d4f441) 67.55% compared to head (7ad099f) 66.76%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #172      +/-   ##
==========================================
- Coverage   67.55%   66.76%   -0.80%     
==========================================
  Files          50       50              
  Lines        4553     4553              
==========================================
- Hits         3076     3040      -36     
- Misses       1080     1108      +28     
- Partials      397      405       +8     
Flag Coverage Δ
e2etests 22.14% <ø> (-0.97%) ⬇️
unit-test 64.27% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

see 5 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@FogDong
Copy link
Member

FogDong commented Sep 27, 2023

Sorry for the late reply, I'm currently at the KubeConCN and will review this after I'm back.

@@ -74,6 +74,27 @@ func TestInput(t *testing.T) {
r.NoError(err)
r.Equal(s, `99
`)

// test array value
Copy link
Member

Choose a reason for hiding this comment

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

🤔Is this PR only for adding test cases?

@drewwells
Copy link
Author

Yeah, I thought it was going to uncover a bug but workflow handles arrays just fine. So this tests that arrays work.
The bug is default behavior of treating integers as keys in maps instead of assuming arrays like it did previously.

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.

2 participants