@Test
	public void testGetCodeUnitsSet2Forward() throws Exception {

		AddressSet set = new AddressSet();
		set.addRange(addr(0x3f2), addr(0x3f2));
		set.addRange(addr(0x3f8), addr(0x3f8));

		CodeUnitIterator it = listing.getCodeUnits(set, true);

		CodeUnit cu = it.next();
		assertEquals(addr(0x3f2), cu.getMinAddress());
		assertTrue(cu instanceof Instruction);

		cu = it.next();
		assertEquals(addr(0x3f8), cu.getMinAddress());
		assertTrue(cu instanceof Data);

		assertFalse(it.hasNext());
		assertNull(it.next());

	}
** Diagnostic Aid ** Open program in tool
@throws Exception
Ghidra/Features/Base/src/test.slow/java/ghidra/program/database/code/CodeUnitIteratorTest.java