MCPcopy Create free account
hub / github.com/defold/defold / SetUp

Method SetUp

engine/resource/src/test/test_provider_http.cpp:78–91  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

76{
77protected:
78 void SetUp() override
79 {
80 m_Loader = dmResourceProvider::FindLoaderByName(dmHashString64("http"));
81 ASSERT_NE((ArchiveLoader*)0, m_Loader);
82
83 char buffer[128];
84 dmSnPrintf(buffer, sizeof(buffer), "http://localhost:%d", PORT);
85
86 dmURI::Parts uri;
87 dmURI::Parse(buffer, &uri);
88
89 dmResourceProvider::Result result = dmResourceProvider::CreateMount(m_Loader, &uri, 0, &m_Archive);
90 ASSERT_EQ(dmResourceProvider::RESULT_OK, result);
91 }
92
93 void TearDown() override
94 {

Callers

nothing calls this directly

Calls 4

FindLoaderByNameFunction · 0.85
dmSnPrintfFunction · 0.85
CreateMountFunction · 0.85
ParseFunction · 0.50

Tested by

no test coverage detected