@@ -139,7 +139,7 @@ public static IMsuCacheService CreateMockMsuCacheService()
139139 return service . Object ;
140140 }
141141
142- public static string CreateMsu ( List < int > tracks , string msuName = "test-msu" , bool deleteOld = true , bool createAlts = false )
142+ public static string CreateMsu ( List < int > tracks , string msuName = "test-msu" , bool deleteOld = true , bool createAlts = false , List < int > ? specialTracks = null )
143143 {
144144 if ( deleteOld && Directory . Exists ( MsuTestFolder ) )
145145 {
@@ -160,9 +160,17 @@ public static string CreateMsu(List<int> tracks, string msuName = "test-msu", bo
160160
161161 foreach ( var trackNumber in tracks )
162162 {
163- var pcmPath = Path . Combine ( folder , $ "{ msuName } -{ trackNumber } .pcm") ;
164- using ( File . Create ( pcmPath ) ) { }
163+ var pcmPath = Path . Combine ( folder , $ "{ msuName } -{ trackNumber } .pcm") ; System . IO . File . WriteAllBytes ( "file.txt" , new byte [ 100 ] ) ;
165164
165+ if ( specialTracks == null || specialTracks . Contains ( trackNumber ) )
166+ {
167+ using ( File . Create ( pcmPath ) ) { }
168+ }
169+ else
170+ {
171+ File . WriteAllBytes ( pcmPath , new byte [ 5292000 ] ) ;
172+ }
173+
166174 if ( createAlts )
167175 {
168176 pcmPath = Path . Combine ( folder , $ "{ msuName } -{ trackNumber } _alt.pcm") ;
@@ -173,9 +181,9 @@ public static string CreateMsu(List<int> tracks, string msuName = "test-msu", bo
173181 return msuPath ;
174182 }
175183
176- public static string CreateMsu ( List < ( int , int ) > tracks , string msuName = "test-msu" , bool deleteOld = true , bool createAlts = false )
184+ public static string CreateMsu ( List < ( int , int ) > tracks , string msuName = "test-msu" , bool deleteOld = true , bool createAlts = false , List < int > ? specialTracks = null )
177185 {
178- return CreateMsu ( GetTracksFromRanges ( tracks ) , msuName , deleteOld , createAlts ) ;
186+ return CreateMsu ( GetTracksFromRanges ( tracks ) , msuName , deleteOld , createAlts , specialTracks ) ;
179187 }
180188
181189 public static IMsuDetailsService CreateMockMsuDetailsService ( MsuDetails ? returnMsuDetails , Msu ? returnMsu )
0 commit comments