Skip to content
This repository has been archived by the owner on Jul 12, 2022. It is now read-only.

refactor: deprecated dynamic input #848

Merged

Conversation

lucasdittrichzup
Copy link
Contributor

Description

In the coming months, due to the formula output feature, the type of dynamic input will be depreciated.

Because of this, this PR adds a warning for users who use this type of input in their formulas, as shown in the GIF below:

gif containing the command demonstration

Close #813

How to verify it

  1. clone this PR (git fetch origin pull / 848 / head: feature/deprecated-dynamic-input)
  2. create a formula with dynamic input
  3. run the formula and check that the warning is displayed

Changelog

Adds depreciation warning of dynamic input

Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
@lucasdittrichzup lucasdittrichzup added 📚 documentation Improvements or additions to documentation deprecation Some function got removed ✔️ ready-for-review ready for review labels Feb 4, 2021
@lucasdittrichzup lucasdittrichzup self-assigned this Feb 4, 2021
Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
if (tt.want != nil && got == nil) || got != nil && got.Error() != tt.want.Error() {
t.Errorf("PostRun(%s) got %v, want %v", tt.name, got, tt.want)
}
assert.Equal(t, tt.want, got)
Copy link
Contributor

Choose a reason for hiding this comment

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

Beautiful, right 🌟

@brunasilvazup brunasilvazup added waiting reply Waiting for an answer to a comment and removed ✔️ ready-for-review ready for review labels Feb 4, 2021
Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
@lucasdittrichzup lucasdittrichzup added ✔️ ready-for-review ready for review and removed waiting reply Waiting for an answer to a comment labels Feb 4, 2021
@codecov-io
Copy link

Codecov Report

Merging #848 (dbe139c) into master (ff8a439) will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #848      +/-   ##
==========================================
+ Coverage   84.34%   84.35%   +0.01%     
==========================================
  Files         113      113              
  Lines        4011     4015       +4     
==========================================
+ Hits         3383     3387       +4     
  Misses        442      442              
  Partials      186      186              
Impacted Files Coverage Δ
pkg/formula/runner/post_run.go 100.00% <100.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 ff8a439...dbe139c. Read the comment docs.

brunasilvazup
brunasilvazup previously approved these changes Feb 4, 2021
Copy link
Contributor

@brunasilvazup brunasilvazup left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@henriquemoraeszup henriquemoraeszup left a comment

Choose a reason for hiding this comment

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

Just to clarify, we cannot consider yet this to be the test refactor. We would still have to remove the filemanagermock and test for the file system side effects

brunasilvazup and others added 5 commits February 8, 2021 14:01
Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
Signed-off-by: lucas.dittrich <lucas.dittrich@zup.com.br>
…ttrichzup/ritchie-cli into feature/deprecated-dynamic-input
@brunasilvazup brunasilvazup merged commit 0249fbb into ZupIT:master Feb 9, 2021
@lucasdittrichzup lucasdittrichzup deleted the feature/deprecated-dynamic-input branch July 21, 2021 19:15
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
📚 documentation Improvements or additions to documentation deprecation Some function got removed ✔️ ready-for-review ready for review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecate the dynamic list
4 participants