forked from mirror/Archipelago
Some checks failed
Analyze modified files / flake8 (push) Failing after 2m28s
Build / build-win (push) Has been cancelled
Build / build-ubuntu2204 (push) Has been cancelled
ctest / Test C++ ubuntu-latest (push) Has been cancelled
ctest / Test C++ windows-latest (push) Has been cancelled
Analyze modified files / mypy (push) Has been cancelled
Build and Publish Docker Images / Push Docker image to Docker Hub (push) Successful in 5m4s
Native Code Static Analysis / scan-build (push) Failing after 5m2s
type check / pyright (push) Successful in 1m7s
unittests / Test Python 3.11.2 ubuntu-latest (push) Failing after 16m23s
unittests / Test Python 3.12 ubuntu-latest (push) Failing after 28m19s
unittests / Test Python 3.13 ubuntu-latest (push) Failing after 14m49s
unittests / Test hosting with 3.13 on ubuntu-latest (push) Successful in 5m0s
unittests / Test Python 3.13 macos-latest (push) Has been cancelled
unittests / Test Python 3.11 windows-latest (push) Has been cancelled
unittests / Test Python 3.13 windows-latest (push) Has been cancelled
113 lines
3.6 KiB
Python
113 lines
3.6 KiB
Python
from worlds.banjo_tooie.Names import itemName, locationName
|
|
from ..Options import KingJingalingHasJiggy, RandomizeJinjos, SkipKlungo, WorldRequirements
|
|
from .test_logic import EasyTricksLogic, GlitchesLogic, HardTricksLogic, IntendedLogic
|
|
from . import BanjoTooieTestBase
|
|
|
|
# This file contains tests of options that barely do anything.
|
|
|
|
|
|
class TestVanillaJingalingJiggy(BanjoTooieTestBase):
|
|
options = {
|
|
"jingaling_jiggy": KingJingalingHasJiggy.option_true,
|
|
"randomize_jinjos": RandomizeJinjos.option_true, # Just so that jinjo jiggies are also in the pool.
|
|
"world_requirements": WorldRequirements.option_custom,
|
|
"custom_worlds": "1,1,1,1,1,1,1,1,61",
|
|
"extra_jiggies_weight": 0,
|
|
}
|
|
|
|
def test_item_pool(self) -> None:
|
|
progression_jiggies = sum(1 for item in self.multiworld.itempool
|
|
if item.advancement and item.name == itemName.JIGGY)
|
|
useful_jiggies = sum(1 for item in self.multiworld.itempool if item.useful and item.name == itemName.JIGGY)
|
|
assert progression_jiggies == 65
|
|
assert useful_jiggies == 10
|
|
|
|
def test_prefill(self) -> None:
|
|
assert [location for location in self.world.get_locations()
|
|
if location.name == locationName.JIGGYIH10][0].item.name == itemName.JIGGY
|
|
|
|
|
|
class TestRandomizedJingalingJiggy(BanjoTooieTestBase):
|
|
options = {
|
|
"jingaling_jiggy": KingJingalingHasJiggy.option_false,
|
|
"randomize_jinjos": RandomizeJinjos.option_true,
|
|
"world_requirements": WorldRequirements.option_custom,
|
|
"custom_worlds": "1,1,1,1,1,1,1,1,61",
|
|
"extra_jiggies_weight": 0,
|
|
}
|
|
|
|
def test_item_pool(self) -> None:
|
|
progression_jiggies = sum(1 for item in self.multiworld.itempool
|
|
if item.advancement and item.name == itemName.JIGGY)
|
|
useful_jiggies = sum(1 for item in self.multiworld.itempool if item.useful and item.name == itemName.JIGGY)
|
|
assert progression_jiggies == 66
|
|
assert useful_jiggies == 10
|
|
|
|
|
|
class TestSkipKlungoEnabled(BanjoTooieTestBase):
|
|
options = {
|
|
"skip_klungo": SkipKlungo.option_true,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoDisabled(BanjoTooieTestBase):
|
|
options = {
|
|
"skip_klungo": SkipKlungo.option_false,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoEnabledIntended(TestSkipKlungoEnabled, IntendedLogic):
|
|
options = {
|
|
**TestSkipKlungoEnabled.options,
|
|
**IntendedLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoEnabledEasyTricks(TestSkipKlungoEnabled, EasyTricksLogic):
|
|
options = {
|
|
**TestSkipKlungoEnabled.options,
|
|
**EasyTricksLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoEnabledHardTricks(TestSkipKlungoEnabled, HardTricksLogic):
|
|
options = {
|
|
**TestSkipKlungoEnabled.options,
|
|
**HardTricksLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoEnabledGlitches(TestSkipKlungoEnabled, GlitchesLogic):
|
|
options = {
|
|
**TestSkipKlungoEnabled.options,
|
|
**GlitchesLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoDisabledIntended(TestSkipKlungoDisabled, IntendedLogic):
|
|
options = {
|
|
**TestSkipKlungoDisabled.options,
|
|
**IntendedLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoDisabledEasyTricks(TestSkipKlungoDisabled, EasyTricksLogic):
|
|
options = {
|
|
**TestSkipKlungoDisabled.options,
|
|
**EasyTricksLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoDisabledHardTricks(TestSkipKlungoDisabled, HardTricksLogic):
|
|
options = {
|
|
**TestSkipKlungoDisabled.options,
|
|
**HardTricksLogic.options,
|
|
}
|
|
|
|
|
|
class TestSkipKlungoDisabledGlitches(TestSkipKlungoDisabled, GlitchesLogic):
|
|
options = {
|
|
**TestSkipKlungoDisabled.options,
|
|
**GlitchesLogic.options,
|
|
}
|