diff options
author | Sefa Eyeoglu <contact@scrumplex.net> | 2022-09-04 15:05:11 +0200 |
---|---|---|
committer | Sefa Eyeoglu <contact@scrumplex.net> | 2022-09-20 10:26:15 +0200 |
commit | aad6f74db6a08ca23a9b4ee7f261a051d230bef7 (patch) | |
tree | 35c219a1334fb020e86d841f0937ed281a34d61b /launcher | |
parent | 07dcefabcbe3436ae6de09bc8c99120ab3f0a745 (diff) | |
download | PrismLauncher-aad6f74db6a08ca23a9b4ee7f261a051d230bef7.tar.gz PrismLauncher-aad6f74db6a08ca23a9b4ee7f261a051d230bef7.tar.bz2 PrismLauncher-aad6f74db6a08ca23a9b4ee7f261a051d230bef7.zip |
fix: tests
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
Diffstat (limited to 'launcher')
5 files changed, 0 insertions, 74 deletions
diff --git a/launcher/minecraft/mod/TexturePackParse_test.cpp b/launcher/minecraft/mod/TexturePackParse_test.cpp deleted file mode 100644 index 207c2c87..00000000 --- a/launcher/minecraft/mod/TexturePackParse_test.cpp +++ /dev/null @@ -1,70 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0-only -/* - * PolyMC - Minecraft Launcher - * Copyright (c) 2022 flowln <flowlnlnln@gmail.com> - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, version 3. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see <https://www.gnu.org/licenses/>. - */ - -#include <QTest> -#include <QTimer> - -#include "FileSystem.h" - -#include "TexturePack.h" -#include "tasks/LocalTexturePackParseTask.h" - -class TexturePackParseTest : public QObject { - Q_OBJECT - - private slots: - void test_parseZIP() - { - QString source = QFINDTESTDATA("testdata"); - - QString zip_rp = FS::PathCombine(source, "test_texture_pack_idk.zip"); - TexturePack pack { QFileInfo(zip_rp) }; - - TexturePackUtils::processZIP(pack); - - QVERIFY(pack.description() == "joe biden, wake up"); - } - - void test_parseFolder() - { - QString source = QFINDTESTDATA("testdata"); - - QString folder_rp = FS::PathCombine(source, "test_texturefolder"); - TexturePack pack { QFileInfo(folder_rp) }; - - TexturePackUtils::processFolder(pack); - - QVERIFY(pack.description() == "Some texture pack surely"); - } - - void test_parseFolder2() - { - QString source = QFINDTESTDATA("testdata"); - - QString folder_rp = FS::PathCombine(source, "another_test_texturefolder"); - TexturePack pack { QFileInfo(folder_rp) }; - - TexturePackUtils::process(pack); - - QVERIFY(pack.description() == "quieres\nfor real"); - } -}; - -QTEST_GUILESS_MAIN(TexturePackParseTest) - -#include "TexturePackParse_test.moc" diff --git a/launcher/minecraft/mod/testdata/another_test_texturefolder/pack.txt b/launcher/minecraft/mod/testdata/another_test_texturefolder/pack.txt deleted file mode 100644 index bbc0d271..00000000 --- a/launcher/minecraft/mod/testdata/another_test_texturefolder/pack.txt +++ /dev/null @@ -1,2 +0,0 @@ -quieres -for real
\ No newline at end of file diff --git a/launcher/minecraft/mod/testdata/test_texture_pack_idk.zip b/launcher/minecraft/mod/testdata/test_texture_pack_idk.zip Binary files differdeleted file mode 100644 index fb4d3370..00000000 --- a/launcher/minecraft/mod/testdata/test_texture_pack_idk.zip +++ /dev/null diff --git a/launcher/minecraft/mod/testdata/test_texturefolder/assets/minecraft/textures/blah.txt b/launcher/minecraft/mod/testdata/test_texturefolder/assets/minecraft/textures/blah.txt deleted file mode 100644 index 8d1c8b69..00000000 --- a/launcher/minecraft/mod/testdata/test_texturefolder/assets/minecraft/textures/blah.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/launcher/minecraft/mod/testdata/test_texturefolder/pack.txt b/launcher/minecraft/mod/testdata/test_texturefolder/pack.txt deleted file mode 100644 index f6260725..00000000 --- a/launcher/minecraft/mod/testdata/test_texturefolder/pack.txt +++ /dev/null @@ -1 +0,0 @@ -Some texture pack surely
\ No newline at end of file |