예제 #1
0
        public void ThrowsArgumentNullException_When_KeyIsInvalid(string key)
        {
            // arrange / act
            var action = new Action(() => _sut.RemoveItem(key));

            // assert
            Assert.Throws <ArgumentNullException>(action);
        }
예제 #2
0
        protected async override Task HandleAsync(LogoutAction action, IDispatcher dispatcher)
        {
            await localStorage.RemoveItem("branch.name");

            await localStorage.RemoveItem("user.name");

            await localStorage.RemoveItem("token");

            api.BranchId = Guid.Empty;

            uriHelper.NavigateTo("/login");
        }
예제 #3
0
 public async ValueTask RemoveItem(string key)
 {
     LocalStorageService.RemoveItem(key);
     await Task.Delay(1);
 }