예제 #1
0
		public void EntryWithTypedNote()
		{
			using (var session = new LiftExportAsFragmentTestSession())
			{
				var sense = new LexSense();
				var note = new LexNote("comic");
				note.SetAlternative("etr", "one");
				sense.Notes.Add(note);
				session.LiftWriter.Add(sense);
				session.LiftWriter.End();
				AssertHasOneMatch("sense/note/form[@lang='etr' and text='one']", session);
				AssertHasOneMatch("sense/note[@type='comic']", session);
			}
		}
예제 #2
0
		public void SenseWith2Notes()
		{
			using (var session = new LiftExportAsFragmentTestSession())
			{
				var sense = new LexSense();
				var note = new LexNote("grammar");
				note.SetAlternative("etr", "one");
				sense.Notes.Add(note);
				var note2 = new LexNote("comment");
				note2.SetAlternative("etr", "blah");
				sense.Notes.Add(note2);
				session.LiftWriter.Add(sense);
				session.LiftWriter.End();
				AssertHasOneMatch("sense/note/form[@lang='etr' and text='one']", session);
				AssertHasOneMatch("sense/note[@type='grammar']", session);
				AssertHasOneMatch("sense/note[@type='comment']", session);
			}
		}