File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed
src/Dataverse.ConfigurationMigrationTool/Console.Tests/Features/Import/Commands Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change 44using Dataverse . ConfigurationMigrationTool . Console . Features . Shared ;
55using Dataverse . ConfigurationMigrationTool . Console . Tests . Extensions ;
66using Microsoft . Extensions . Logging ;
7+ using Microsoft . Extensions . Options ;
78using NSubstitute ;
89using Shouldly ;
910
@@ -17,17 +18,25 @@ public class ImportCommandsTest
1718 private readonly ImportCommands _importCommands ;
1819 const string DataFilePath = "data.json" ;
1920 const string SchemaFilePath = "schema.json" ;
21+ private ImportCommandOptions _options => new ( )
22+ {
23+ data = DataFilePath ,
24+ schema = SchemaFilePath
25+ } ;
2026
2127 public ImportCommandsTest ( )
2228 {
2329 _logger = Substitute . For < ILogger < ImportCommands > > ( ) ;
2430 _importDataProvider = Substitute . For < IImportDataProvider > ( ) ;
2531 _schemaValidator = Substitute . For < IValidator < ImportSchema > > ( ) ;
2632 _importDataService = Substitute . For < IImportTaskProcessorService > ( ) ;
33+ var options = Substitute . For < IOptions < ImportCommandOptions > > ( ) ;
34+ options . Value . Returns ( _options ) ;
2735 _importCommands = new ImportCommands ( _logger ,
2836 _importDataProvider ,
2937 _schemaValidator ,
30- _importDataService ) ;
38+ _importDataService ,
39+ options ) ;
3140 }
3241
3342 [ Fact ]
You can’t perform that action at this time.
0 commit comments