Commit 24460c4a authored by Ján Kušnír's avatar Ján Kušnír
Browse files

small SettingsController test fixes

parent aa84c96f
Loading
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -221,12 +221,14 @@ public class StockWebApiTests
    public async Task Test_WhenPathIsEmpty_Then_ArgumentExceptionIsThrown()
    {
        var client = _factory.CreateClient();
        var stringContent = new StringContent("");
        Microsoft.AspNetCore.Mvc.OkResult response = null;
        StockStorageLocation stockStorageLocation = new StockStorageLocation();
        stockStorageLocation.Location = "";
        var jsonContent = JsonContent.Create(stockStorageLocation);

        try
        {
            await client.PostAsync("/StockSettings", stringContent);
            await client.PostAsync("/StockSettings", jsonContent);
        }
        catch (System.Exception err)
        {
@@ -237,7 +239,7 @@ public class StockWebApiTests
    }

    [Test]
    public async Task Test_WhenChengingDirectory_Then_OkIsReturned()
    public async Task Test_WhenChangingDirectory_Then_OkIsReturned()
    {
        Directory.CreateDirectory("filesystem2");
        var client = _factory.CreateClient();