public async void NetZoneTests(NetZoneEnum netZone, string extension, WopiActionEnum action, string expectedValue, string fileName)
        {
            // Arrange
            InitDiscoverer(fileName, netZone);

            // Act
            var result = await _wopiDiscoverer.GetUrlTemplateAsync(extension, action);

            // Assert
            Assert.Equal(expectedValue, result);
        }
Exemple #2
0
 public WopiDiscoverer(IDiscoveryFileProvider discoveryFileProvider, NetZoneEnum netZone = NetZoneEnum.Any)
 {
     DiscoveryFileProvider = discoveryFileProvider;
     NetZone = netZone;
 }
 private void InitDiscoverer(string fileName, NetZoneEnum netZone = NetZoneEnum.Any)
 {
     _wopiDiscoverer = new WopiDiscoverer(new FileSystemDiscoveryFileProvider(Path.Combine(System.AppContext.BaseDirectory, fileName)), netZone);
 }