@Test
    public void testCategoryAddedInLatest() throws Exception {

		// A category was added to Category5 in the latest; 
		// in My program, rename Category5 to "My Category5"
		mtf.initialize("notepad", new ProgramModifierListener() {
	
			@Override
			public void modifyLatest(ProgramDB program) {
				Category c = program.getDataTypeManager().getCategory(
					new CategoryPath("/Category1/Category2/Category5"));
				try {
					c.createCategory("AnotherCategory");
				}
				catch (InvalidNameException e) {
					Assert.fail("Got Invalid Name Exception! " + e.getMessage());
				}
			}

			@Override
			public void modifyPrivate(ProgramDB program) {
				DataTypeManager dtm = program.getDataTypeManager();
				// move /Category1/Category2/Category5 to
				// /Category1/Category2/Category3
				Category c = dtm.getCategory(new CategoryPath("/Category1/Category2/Category5"));
				try {
					c.setName("My Category5");
				}
				catch (DuplicateNameException e) {
					Assert.fail("Got Duplicate name exception!");
				}
				catch (InvalidNameException e) {
					Assert.fail("Got InvalidNameException!");
				}
			}
		});

		executeMerge(-1);
		// should end up with /Category1/Category2/My Category5/AnotherCategory
		DataTypeManager dtm = resultProgram.getDataTypeManager();

		Category c = dtm.getCategory(new CategoryPath("/Category1/Category2"));
		c = c.getCategory("My Category5");
		assertNotNull(c);
		assertNotNull(c.getCategory("AnotherCategory"));
	}
Tests for the merge data type manager.
Ghidra/Features/Base/src/test.slow/java/ghidra/app/merge/datatypes/CategoryMerge1Test.java