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

Remove deadcode from test helpers. #4647

Merged
merged 1 commit into from Oct 8, 2019
Merged

Remove deadcode from test helpers. #4647

merged 1 commit into from Oct 8, 2019

Conversation

rabbah
Copy link
Member

@rabbah rabbah commented Sep 27, 2019

Removes code that appears dead in this project/tests.
Closes #3863.

Description

Related issue and scope

  • I opened an issue to propose and discuss this change (#????)

My changes affect the following components

  • API
  • Controller
  • Message Bus (e.g., Kafka)
  • Loadbalancer
  • Invoker
  • Intrinsic actions (e.g., sequences, conductors)
  • Data stores (e.g., CouchDB)
  • Tests
  • Deployment
  • CLI
  • General tooling
  • Documentation

Types of changes

  • Bug fix (generally a non-breaking change which closes an issue).
  • Enhancement or new feature (adds new functionality).
  • Breaking change (a bug fix or enhancement which changes existing behavior).

Checklist:

  • I signed an Apache CLA.
  • I reviewed the style guides and followed the recommendations (Travis CI will check :).
  • I added tests to cover my changes.
  • My changes require further changes to the documentation.
  • I updated the documentation where necessary.

@codecov-io
Copy link

Codecov Report

Merging #4647 into master will decrease coverage by 5.65%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #4647      +/-   ##
==========================================
- Coverage   84.44%   78.78%   -5.66%     
==========================================
  Files         183      183              
  Lines        8377     8377              
  Branches      566      566              
==========================================
- Hits         7074     6600     -474     
- Misses       1303     1777     +474
Impacted Files Coverage Δ
...core/database/cosmosdb/RxObservableImplicits.scala 0% <0%> (-100%) ⬇️
...ore/database/cosmosdb/cache/CacheInvalidator.scala 0% <0%> (-100%) ⬇️
...core/database/cosmosdb/CosmosDBArtifactStore.scala 0% <0%> (-95.89%) ⬇️
...tabase/cosmosdb/cache/CacheInvalidatorConfig.scala 0% <0%> (-94.74%) ⬇️
...sk/core/database/cosmosdb/CosmosDBViewMapper.scala 0% <0%> (-92.6%) ⬇️
...e/database/cosmosdb/cache/ChangeFeedListener.scala 0% <0%> (-86.67%) ⬇️
...e/database/cosmosdb/cache/KafkaEventProducer.scala 0% <0%> (-76.48%) ⬇️
...whisk/core/database/cosmosdb/CosmosDBSupport.scala 0% <0%> (-74.08%) ⬇️
...a/org/apache/openwhisk/common/ExecutorCloser.scala 0% <0%> (-66.67%) ⬇️
...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala 4% <0%> (-52%) ⬇️
... and 8 more

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 a581bea...9dea3a6. Read the comment docs.

Copy link
Contributor

@BillZong BillZong left a comment

Choose a reason for hiding this comment

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

Checked. LGTM

@mhenke1
Copy link
Contributor

mhenke1 commented Oct 8, 2019

@rabbah we have found time to adapt the affected test cases. Thanks for waiting with the merge

Copy link
Contributor

@mhenke1 mhenke1 left a comment

Choose a reason for hiding this comment

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

LGTM

*
* @return VCAP_SERVICES as a JSON object
*/
public static JsonObject getVCAPServices() {
Copy link
Contributor

Choose a reason for hiding this comment

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

@rabbah
Unfortunately there are tests specific to IBM Functions using getVCAPServices (and with it vcapFile).
Leaving these two things in for now would give our team time to adapt changes without direct pressure.

getVCAPcredentials, getCredentials and DEFAULT_CONCURRENCY are not used.
If there is agreement I would like ask to remove the later ones only and get to the used ones in a later PR.

@mhenke1 mhenke1 merged commit 15709b6 into apache:master Oct 8, 2019
@dubee
Copy link
Member

dubee commented Oct 11, 2019

@rabbah, @mhenke1, the providers use getCredentials().

@jasonpet
Copy link
Contributor

this needs to be reverted. there are openwhisk repos that use the removed utils. openwhisk is made up of many repos/projects and you cannot remove utils just because you do not see them being used in this repo/project.

@rabbah
Copy link
Member Author

rabbah commented Oct 11, 2019

Thanks @dubee for pointing that out. I didn't mark this PR ready for review or notify the dev list because I did in fact intend to move the related code to the providers. I'm aware the providers need them (see the corresponding issue from July 2018). I'm not sure why this was merged yet (the message from Martin did suggest time was needed to address dependencies).

@rabbah
Copy link
Member Author

rabbah commented Oct 11, 2019

FWIW, It's OK with me to revert the PR. I can reintroduce the patch when the downstream dependencies are resolved.

@rabbah rabbah mentioned this pull request Oct 11, 2019
21 tasks
@rabbah rabbah deleted the tests branch December 18, 2019 13:01
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.

missing null check during TestUtils initialization
6 participants