Complete management API and CLI command parity
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using Microsoft.JSInterop;
|
||||
using System.Security.Claims;
|
||||
using System.Text.Json;
|
||||
using ZB.MOM.WW.ScadaBridge.Security;
|
||||
@@ -34,6 +35,13 @@ namespace ZB.MOM.WW.ScadaBridge.CentralUI.Tests;
|
||||
/// </summary>
|
||||
public class TopologyPageTests : BunitContext
|
||||
{
|
||||
[Fact]
|
||||
public void StorageSaveFixture_CompletesInvocationImmediately()
|
||||
{
|
||||
var invocation = JSInterop.JSRuntime.InvokeVoidAsync("treeviewStorage.save", "fixture-probe", "[]");
|
||||
Assert.True(invocation.IsCompletedSuccessfully, "The storage-save fixture must complete JS calls before component disposal.");
|
||||
}
|
||||
|
||||
private readonly ITemplateEngineRepository _repo = Substitute.For<ITemplateEngineRepository>();
|
||||
private readonly ISiteRepository _siteRepo = Substitute.For<ISiteRepository>();
|
||||
private readonly IDeploymentManagerRepository _deployRepo = Substitute.For<IDeploymentManagerRepository>();
|
||||
@@ -97,7 +105,7 @@ public class TopologyPageTests : BunitContext
|
||||
|
||||
// TreeView persists expansion state via JS interop. Stub the calls so render doesn't throw.
|
||||
JSInterop.Setup<string?>("treeviewStorage.load", _ => true).SetResult(null);
|
||||
JSInterop.SetupVoid("treeviewStorage.save", _ => true);
|
||||
JSInterop.SetupVoid("treeviewStorage.save", _ => true).SetVoidResult();
|
||||
}
|
||||
|
||||
private void AddTestAuth()
|
||||
|
||||
Reference in New Issue
Block a user