Clean up stale editor-hInstance comments, add isOwnModulePath edge tests
Drops a false claim about ReaSampler's own editor's hInstance, corrects the real reason for registering the wndproc class against our own module, and covers isOwnModulePath's separator edge cases.
This commit is contained in:
@@ -194,6 +194,18 @@ static void testOwnModulePathStableAndBetaDoNotMatchEachOther() {
|
||||
CHECK(!isOwnModulePath("C:\\VST3\\reasampler_9000.vst3", "reasampler_9000_beta.vst3"));
|
||||
}
|
||||
|
||||
static void testOwnModulePathBareFilenameWithNoSeparatorMatches() {
|
||||
CHECK(isOwnModulePath("reasampler_9000.vst3", "reasampler_9000.vst3"));
|
||||
}
|
||||
|
||||
static void testOwnModulePathEmptyPathDoesNotMatch() {
|
||||
CHECK(!isOwnModulePath("", "reasampler_9000.vst3"));
|
||||
}
|
||||
|
||||
static void testOwnModulePathTrailingSeparatorDoesNotMatch() {
|
||||
CHECK(!isOwnModulePath("C:\\VST3\\reasampler_9000.vst3\\", "reasampler_9000.vst3"));
|
||||
}
|
||||
|
||||
int main() {
|
||||
testHostExecutableIsHost();
|
||||
testOsModulesAreSystem();
|
||||
@@ -216,6 +228,9 @@ int main() {
|
||||
testOwnModulePathCaseFolds();
|
||||
testOwnModulePathBundlePathForwardAndBackSlash();
|
||||
testOwnModulePathStableAndBetaDoNotMatchEachOther();
|
||||
testOwnModulePathBareFilenameWithNoSeparatorMatches();
|
||||
testOwnModulePathEmptyPathDoesNotMatch();
|
||||
testOwnModulePathTrailingSeparatorDoesNotMatch();
|
||||
|
||||
if (g_fail == 0) std::printf("All tests passed.\n");
|
||||
return g_fail ? 1 : 0;
|
||||
|
||||
Reference in New Issue
Block a user