public void SlotNextInSegment_OnFirstSlotInPaduakTestSegment_ReturnsNonNullSlot() { using (var seg = new PaduakDisposableTestSegment("hello world")) { IntPtr slot = Graphite2Api.SegFirstSlot(seg.Seg); Assert.AreNotEqual(IntPtr.Zero, Graphite2Api.SlotNextInSegment(slot)); } }
public void SlotPrevInSegment_OnSecondSlotInPaduakTestSegment_ReturnsNonNullSlot() { using (var seg = new PaduakDisposableTestSegment("hello world")) { IntPtr firstSlot = Graphite2Api.SegFirstSlot(seg.Seg); IntPtr secondSlot = Graphite2Api.SlotNextInSegment(firstSlot); Assert.AreNotEqual(IntPtr.Zero, Graphite2Api.SlotPrevInSegment(secondSlot), "returned null slot"); Assert.AreEqual(firstSlot, Graphite2Api.SlotPrevInSegment(secondSlot), "should equal first slot"); } }