Created
July 17, 2021 18:48
-
-
Save rubenwardy/1d4d5f068054fdf8dc0e176e40f2c4b9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Test(ModOrderResolverRedundantTests) { | |
std::vector<ModConfig> mods; | |
mods.push_back({ | |
"modB", | |
"rubenwardy", | |
"", | |
std::vector<std::string>{"modC"} | |
}); | |
mods.push_back({ | |
"modA", | |
"rubenwardy", | |
"", | |
std::vector<std::string>{"modB", "modC"}, | |
}); | |
mods.push_back({ | |
"modC", | |
"rubenwardy", | |
"", | |
{}, | |
}); | |
ModOrderResolver resolver(mods); | |
auto orderedMods = resolver.resolve(); | |
Assert(orderedMods[0].name == "modC"); | |
Assert(orderedMods[1].name == "modB"); | |
Assert(orderedMods[2].name == "modA"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment