| 101 | |
| 102 | |
| 103 | TEST_F(CurlFetcherPluginTest, CURL_ValidUri) |
| 104 | { |
| 105 | URI uri = uri::http( |
| 106 | stringify(server.self().address.ip), |
| 107 | "/TestHttpServer/test", |
| 108 | server.self().address.port); |
| 109 | |
| 110 | EXPECT_CALL(server, test(_)) |
| 111 | .WillOnce(Return(http::OK("test"))); |
| 112 | |
| 113 | Try<Owned<uri::Fetcher>> fetcher = uri::fetcher::create(); |
| 114 | ASSERT_SOME(fetcher); |
| 115 | |
| 116 | AWAIT_READY(fetcher.get()->fetch(uri, os::getcwd())); |
| 117 | |
| 118 | EXPECT_TRUE(os::exists(path::join(os::getcwd(), "test"))); |
| 119 | } |
| 120 | |
| 121 | |
| 122 | TEST_F(CurlFetcherPluginTest, CURL_ValidUriWithOutputFileName) |
nothing calls this directly
no test coverage detected