Skip to content

Commit

Permalink
[remote] Improve .netrc test in RemoteModuleTest
Browse files Browse the repository at this point in the history
The return value being non-null doesn't assert that we actually parsed the (expected) `.netrc`.

Closes #15902.

PiperOrigin-RevId: 461583660
Change-Id: I0cd9a56c79a2177d89f67e2c541f38eb0ca24dcb
  • Loading branch information
Yannic authored and copybara-github committed Jul 18, 2022
1 parent 8a19544 commit 33516e2
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -566,6 +566,8 @@ public void testNetrc_netrcWithoutRemoteCache() throws Exception {
clientEnv, fileSystem, reporter, authAndTLSOptions, remoteOptions);

assertThat(credentials).isNotNull();
assertThat(credentials.getRequestMetadata(URI.create("https://foo.example.org"))).isNotEmpty();
assertThat(credentials.getRequestMetadata(URI.create("https://bar.example.org"))).isEmpty();
}

private static void assertRequestMetadata(
Expand Down

0 comments on commit 33516e2

Please sign in to comment.