@@ -7,9 +7,12 @@ import {
77} from '../../../../utils/InstallLogicUtils' ;
88import { PluginInstallers } from '../../../../../../src/installers/registry' ;
99import { InstallRulePluginInstaller } from '../../../../../../src/installers/InstallRulePluginInstaller' ;
10+ import { ShimloaderInstaller } from '../../../../../../src/installers/ShimloaderInstaller' ;
11+ import { getInstallArgs } from '../../../../../../src/installers/PackageInstaller' ;
1012import { PackageLoader } from '../../../../../../src/model/schema/ThunderstoreSchema' ;
1113import Profile from '../../../../../../src/model/Profile' ;
1214import R2Error from '../../../../../../src/model/errors/R2Error' ;
15+ import InMemoryFsProvider from '../../../../stubs/providers/InMemory.FsProvider' ;
1316import ProfileInstallerProvider from '../../../../../../src/providers/ror2/installing/ProfileInstallerProvider' ;
1417import GenericProfileInstaller from '../../../../../../src/r2mm/installing/profile_installers/GenericProfileInstaller' ;
1518import { RuleSubtype } from '../../../../../../src/r2mm/installing/InstallationRules' ;
@@ -137,4 +140,45 @@ describe('Shimloader Installer Tests', () => {
137140 await expectFilesToBeCopied ( sourceToExpectedDestination ) ;
138141 } ) ;
139142 } ) ;
143+
144+ describe ( 'Mod loader installation (case-sensitive FS)' , ( ) => {
145+
146+ // Test https://github.com/ebkr/r2modmanPlus/issues/2079
147+ beforeEach ( async ( ) => {
148+ await installLogicBeforeEach ( "Palworld" ) ;
149+ InMemoryFsProvider . setMatchMode ( "CASE_SENSITIVE" ) ;
150+ } ) ;
151+
152+ test ( "Installs new UE4SS.dll" , async ( ) => {
153+ const pkg = createManifest ( "unreal_shimloader" , "Thunderstore" ) ;
154+ const sourceToExpectedDestination = {
155+ "dwmapi.dll" : "dwmapi.dll" ,
156+ "UE4SS/UE4SS.dll" : "ue4ss.dll" ,
157+ "UE4SS/UE4SS-settings.ini" : "UE4SS-settings.ini" ,
158+ "UE4SS/Mods/shared/Types.lua" : "shimloader/mod/shared/Types.lua" ,
159+ } ;
160+ await createPackageFilesIntoCache ( pkg , Object . keys ( sourceToExpectedDestination ) ) ;
161+
162+ const profile = Profile . getActiveProfile ( ) . asImmutableProfile ( ) ;
163+ await new ShimloaderInstaller ( ) . install ( getInstallArgs ( pkg , profile ) ) ;
164+
165+ await expectFilesToBeCopied ( sourceToExpectedDestination ) ;
166+ } ) ;
167+
168+ test ( "Installs old ue4ss.dll" , async ( ) => {
169+ const pkg = createManifest ( "unreal_shimloader" , "Thunderstore" ) ;
170+ const sourceToExpectedDestination = {
171+ "dwmapi.dll" : "dwmapi.dll" ,
172+ "UE4SS/ue4ss.dll" : "ue4ss.dll" ,
173+ "UE4SS/UE4SS-settings.ini" : "UE4SS-settings.ini" ,
174+ "UE4SS/Mods/shared/Types.lua" : "shimloader/mod/shared/Types.lua" ,
175+ } ;
176+ await createPackageFilesIntoCache ( pkg , Object . keys ( sourceToExpectedDestination ) ) ;
177+
178+ const profile = Profile . getActiveProfile ( ) . asImmutableProfile ( ) ;
179+ await new ShimloaderInstaller ( ) . install ( getInstallArgs ( pkg , profile ) ) ;
180+
181+ await expectFilesToBeCopied ( sourceToExpectedDestination ) ;
182+ } ) ;
183+ } ) ;
140184} ) ;
0 commit comments