|
|
@ -38,7 +38,7 @@ namespace Notus_UnitTest_User
|
|
|
|
[Test]
|
|
|
|
[Test]
|
|
|
|
public void SearchFavoriteNoteByName_ShouldReturnMatchingNotes()
|
|
|
|
public void SearchFavoriteNoteByName_ShouldReturnMatchingNotes()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
List<Note> searchedNotes = owner.SearchFavoriteNoteByName(owner.GetNoteList(), searchName);
|
|
|
|
List<Note> searchedNotes = owner.SearchNoteByName(owner.GetFavList(), searchName);
|
|
|
|
Assert.That(searchedNotes, Has.Count.EqualTo(4));
|
|
|
|
Assert.That(searchedNotes, Has.Count.EqualTo(4));
|
|
|
|
CollectionAssert.Contains(searchedNotes, owner.GetNoteList()[0]);
|
|
|
|
CollectionAssert.Contains(searchedNotes, owner.GetNoteList()[0]);
|
|
|
|
CollectionAssert.Contains(searchedNotes, owner.GetNoteList()[1]);
|
|
|
|
CollectionAssert.Contains(searchedNotes, owner.GetNoteList()[1]);
|
|
|
@ -49,7 +49,7 @@ namespace Notus_UnitTest_User
|
|
|
|
public void SearchFavoriteNoteByName_ShouldReturnEmptyList_WhenNoMatchFound()
|
|
|
|
public void SearchFavoriteNoteByName_ShouldReturnEmptyList_WhenNoMatchFound()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
searchName = "nonexistent";
|
|
|
|
searchName = "nonexistent";
|
|
|
|
List<Note> searchedNotes = owner.SearchFavoriteNoteByName(owner.GetNoteList(), searchName);
|
|
|
|
List<Note> searchedNotes = owner.SearchNoteByName(owner.GetFavList(), searchName);
|
|
|
|
Assert.That(searchedNotes, Is.Empty);
|
|
|
|
Assert.That(searchedNotes, Is.Empty);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|