MCPcopy Create free account
hub / github.com/apache/mesos / setBasicHttpAuthenticator

Method setBasicHttpAuthenticator

src/tests/files_tests.cpp:68–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66{
67protected:
68 void setBasicHttpAuthenticator(
69 const string& realm,
70 const Credentials& credentials)
71 {
72 Try<process::http::authentication::Authenticator*> authenticator =
73 BasicAuthenticatorFactory::create(realm, credentials);
74
75 ASSERT_SOME(authenticator);
76
77 // Add this realm to the set of realms which will be unset during teardown.
78 realms.insert(realm);
79
80 // Pass ownership of the authenticator to libprocess.
81 AWAIT_READY(setAuthenticator(
82 realm,
83 Owned<process::http::authentication::Authenticator>(
84 authenticator.get())));
85 }
86
87 void TearDown() override
88 {

Callers

nothing calls this directly

Calls 4

setAuthenticatorFunction · 0.85
insertMethod · 0.80
createFunction · 0.50
getMethod · 0.45

Tested by

no test coverage detected