mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-01-16 15:16:53 +01:00
* wip... * x * . * . * . * r * 1.4.21-preview-02 * 1.4.21-preview-03 * . * usings * wip * . * ut * . * . * . * tests * . * comments * readme
31 lines
821 B
C#
31 lines
821 B
C#
using System.IO;
|
|
using System.Linq;
|
|
using FluentAssertions;
|
|
using WireMock.Server;
|
|
using Xunit;
|
|
|
|
namespace WireMock.Net.Tests
|
|
{
|
|
public class WireMockServerImportWireMockOrgTests
|
|
{
|
|
// For for AppVeyor + OpenCover
|
|
private string GetCurrentFolder()
|
|
{
|
|
return Directory.GetCurrentDirectory();
|
|
}
|
|
|
|
[Fact]
|
|
public void WireMockServer_Admin_ReadStaticWireMockOrgMappingAndAddOrUpdate()
|
|
{
|
|
var server = WireMockServer.Start();
|
|
string path = Path.Combine(GetCurrentFolder(), "__admin", "mappings.org", "mapping1.json");
|
|
server.ReadStaticWireMockOrgMappingAndAddOrUpdate(path);
|
|
|
|
var mappings = server.Mappings.ToArray();
|
|
|
|
mappings.Should().HaveCount(1);
|
|
|
|
server.Stop();
|
|
}
|
|
}
|
|
} |