Esempio n. 1
0
        public async Task ListFilterWorks()
        {
            var handler = new core.Notes.List.Handler(Fixture.CreateStorageWithNotes());

            var query = new core.Notes.List.Query(NotesTestsFixture.UserId, "filtered");

            var response = await handler.Handle(query, CancellationToken.None);

            Assert.Empty(response.Notes);

            query = new core.Notes.List.Query(NotesTestsFixture.UserId, NotesTestsFixture.Ticker);

            response = await handler.Handle(query, CancellationToken.None);

            Assert.Single(response.Notes);
        }
Esempio n. 2
0
        public async Task ListWorks()
        {
            var handler = new core.Notes.List.Handler(Fixture.CreateStorageWithNotes());

            var query = new core.Notes.List.Query(NotesTestsFixture.UserId, null);

            var response = await handler.Handle(query, CancellationToken.None);

            Assert.Single(response.Notes);
        }