Skip to content
This repository was archived by the owner on Apr 2, 2026. It is now read-only.

fix(test): update NIOTest to ensure LocalStorageHelper is used#552

Merged
gcf-merge-on-green[bot] merged 1 commit intomasterfrom
nio-test-fix
May 11, 2021
Merged

fix(test): update NIOTest to ensure LocalStorageHelper is used#552
gcf-merge-on-green[bot] merged 1 commit intomasterfrom
nio-test-fix

Conversation

@BenWhitehead
Copy link
Copy Markdown
Collaborator

When starting a test, there is a gs:// uri which is referenced before any unit test level configuration of CloudStorageFileSystemProvider. If NIOTest runs as the first test in the JVM, CloudStorageFileSystemProvider will initialize internally using all default options (which are production endpoints).

This fix ensures that before the gs:// uri is resolved in the NIOTests that LocalStorageHelper is configured rather than defaults.

When starting a test, there is a `gs://` uri which is referenced before any unit test level configuration of CloudStorageFileSystemProvider. If NIOTest runs as the first test in the JVM, CloudStorageFileSystemProvider will initialize internally using all default options (which are production endpoints).

This fix ensures that before the `gs://` uri is resolved in the NIOTests that LocalStorageHelper is configured rather than defaults.
@BenWhitehead BenWhitehead requested a review from a team May 11, 2021 21:42
@product-auto-label product-auto-label bot added the api: storage Issues related to the googleapis/java-storage-nio API. label May 11, 2021
@google-cla google-cla bot added the cla: yes This human has signed the Contributor License Agreement. label May 11, 2021
@codecov
Copy link
Copy Markdown

codecov bot commented May 11, 2021

Codecov Report

Merging #552 (4566cd9) into master (849c859) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master     #552   +/-   ##
=========================================
  Coverage     72.57%   72.57%           
  Complexity      500      500           
=========================================
  Files            29       29           
  Lines          1670     1670           
  Branches        276      276           
=========================================
  Hits           1212     1212           
  Misses          335      335           
  Partials        123      123           

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 849c859...4566cd9. Read the comment docs.

@Neenu1995 Neenu1995 added the automerge Merge the pull request once unit tests and other checks pass. label May 11, 2021
@gcf-merge-on-green gcf-merge-on-green bot merged commit e0cd38d into master May 11, 2021
@gcf-merge-on-green gcf-merge-on-green bot deleted the nio-test-fix branch May 11, 2021 21:52
@gcf-merge-on-green gcf-merge-on-green bot removed the automerge Merge the pull request once unit tests and other checks pass. label May 11, 2021
gcf-merge-on-green bot pushed a commit that referenced this pull request May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

api: storage Issues related to the googleapis/java-storage-nio API. cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants