MCPcopy Create free account
hub / github.com/FreesmTeam/FreesmLauncher / test_onenine_native_arch

Method test_onenine_native_arch

tests/Library_test.cpp:306–324  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

304 "lwjgl-platform-2.9.4-nightly-20150209-natives-osx.jar"));
305 }
306 void test_onenine_native_arch()
307 {
308 RuntimeContext r = dummyContext("windows");
309 auto test = readMojangJson(QFINDTESTDATA("testdata/Library/lib-native-arch.json"));
310 QStringList jar, native, native32, native64;
311 test->getApplicableFiles(r, jar, native, native32, native64, QString());
312 QCOMPARE(jar, {});
313 QCOMPARE(native, {});
314 QCOMPARE(native32, getStorage("tv/twitch/twitch-platform/5.16/twitch-platform-5.16-natives-windows-32.jar"));
315 QCOMPARE(native64, getStorage("tv/twitch/twitch-platform/5.16/twitch-platform-5.16-natives-windows-64.jar"));
316 QStringList failedFiles;
317 auto dls = test->getDownloads(r, cache.get(), failedFiles, QString());
318 QCOMPARE(dls.size(), 2);
319 QCOMPARE(failedFiles, {});
320 QCOMPARE(dls[0]->url(),
321 QUrl("https://libraries.minecraft.net/tv/twitch/twitch-platform/5.16/twitch-platform-5.16-natives-windows-32.jar"));
322 QCOMPARE(dls[1]->url(),
323 QUrl("https://libraries.minecraft.net/tv/twitch/twitch-platform/5.16/twitch-platform-5.16-natives-windows-64.jar"));
324 }
325
326 private:
327 std::unique_ptr<HttpMetaCache> cache;

Callers

nothing calls this directly

Calls 7

QStringClass · 0.85
QUrlClass · 0.85
getApplicableFilesMethod · 0.80
getDownloadsMethod · 0.80
getMethod · 0.45
sizeMethod · 0.45
urlMethod · 0.45

Tested by

no test coverage detected