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

Samples: Refactor Sample Test 0.40 #319

Conversation

pkirch
Copy link

@pkirch pkirch commented Jul 5, 2022

What this PR changes/adds

  1. Refactor FileTransferSampleTest.java into FileTransferSampleTestUtils.java by creating a test fixture.
  2. Code from FileTransferSampleTest.java has been moved into FileTransferSampleTestUtils.java.
  3. Class FileTransferSampleTest.java instanciates an instance of FileTransferSampleTestUtils.java and uses the moved code respectively.
  4. No test code added or changed!

Why it does that

This PR contains a refactoring to enable the removal of duplicate code from branch feature/1535/254-automated-test-sample-041 which already contains a working integration test for sample 04.1.

Further notes

Successor of this PR: #317

Linked Issue(s)

Contributes to #254.

Checklist

  • added appropriate tests?
  • performed checkstyle check locally?
  • added/updated copyright headers?
  • documented public classes/methods?
  • added/updated relevant documentation?
  • added relevant details to the changelog? (skip with label no-changelog)
  • formatted title correctly? (take a look at the CONTRIBUTING and styleguide for details)

@pkirch pkirch added the no-changelog Used for a workflow label Jul 5, 2022
@pkirch pkirch self-assigned this Jul 5, 2022
@github-actions
Copy link

github-actions bot commented Jul 5, 2022

Unit Test Results

     427 files  ±0       427 suites  ±0   22m 46s ⏱️ + 2m 19s
12 462 tests ±0  12 448 ✔️ ±0  14 💤 ±0  0 ±0 
12 529 runs  ±0  12 515 ✔️ ±0  14 💤 ±0  0 ±0 

Results for commit 774980a. ± Comparison against base commit c817a94.

♻️ This comment has been updated with latest results.

@pkirch pkirch temporarily deployed to Azure-dev July 5, 2022 13:16 Inactive
@pkirch pkirch temporarily deployed to Azure-dev July 5, 2022 13:19 Inactive
@codecov-commenter
Copy link

codecov-commenter commented Jul 5, 2022

Codecov Report

Merging #319 (774980a) into feature/1535-automated-tests-sample-041 (c817a94) will not change coverage.
The diff coverage is n/a.

@@                           Coverage Diff                            @@
##           feature/1535-automated-tests-sample-041     #319   +/-   ##
========================================================================
  Coverage                                    67.77%   67.77%           
========================================================================
  Files                                          759      759           
  Lines                                        16401    16401           
  Branches                                      1049     1049           
========================================================================
  Hits                                         11116    11116           
  Misses                                        4806     4806           
  Partials                                       479      479           

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 c817a94...774980a. Read the comment docs.

@pkirch pkirch temporarily deployed to Azure-dev July 5, 2022 13:31 Inactive
@pkirch pkirch temporarily deployed to Azure-dev July 5, 2022 13:31 Inactive
@pkirch pkirch marked this pull request as ready for review July 5, 2022 13:50
@pkirch pkirch requested a review from paullatzelsperger as a code owner July 5, 2022 13:50
@pkirch pkirch marked this pull request as draft July 5, 2022 13:51
@pkirch pkirch removed the request for review from paullatzelsperger July 5, 2022 13:51
@pkirch pkirch marked this pull request as ready for review July 5, 2022 13:53
Copy link

@chrislomonico chrislomonico left a comment

Choose a reason for hiding this comment

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

refactoring for reuse and avoiding duplicate code is a good approach

@pkirch pkirch temporarily deployed to Azure-dev July 6, 2022 16:26 Inactive
@pkirch pkirch temporarily deployed to Azure-dev July 6, 2022 16:26 Inactive
Copy link

@cpeeyush cpeeyush left a comment

Choose a reason for hiding this comment

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

Approved with suggestions.

@pkirch pkirch temporarily deployed to Azure-dev July 7, 2022 09:16 Inactive
@pkirch pkirch temporarily deployed to Azure-dev July 7, 2022 09:16 Inactive
@pkirch pkirch merged commit a10aad6 into feature/1535-automated-tests-sample-041 Jul 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-changelog Used for a workflow
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants