@Test
	public void testAddExternalFunctionsWithAddressConflict() throws Exception {

		mtf.initialize("notepad", new ProgramModifierListener() {

			@Override
			public void modifyLatest(ProgramDB program) {
				try {
					createExternalFunction(program, new String[] { "user32.dll", "BETTY" },
						addr(program, "1002239"), null, SourceType.USER_DEFINED);
					createExternalFunction(program, new String[] { "user32.dll", "BARNEY" },
						addr(program, "77db1020"), null, SourceType.USER_DEFINED);
				}
				catch (Exception e) {
					Assert.fail(e.getMessage());
				}
			}

			@Override
			public void modifyPrivate(ProgramDB program) {
				try {
					createExternalFunction(program, new String[] { "user32.dll", "BETTY" },
						addr(program, "10063b4"));
					createExternalFunction(program, new String[] { "user32.dll", "BARNEY" },
						addr(program, "77db1130"));
				}
				catch (Exception e) {
					Assert.fail(e.getMessage());
				}
			}
		});

		executeMerge(ASK_USER);

		chooseButtonAndApply("Resolve External Add Conflict",
			ExternalFunctionMerger.KEEP_BOTH_BUTTON_NAME);

		chooseButtonAndApply("Resolve External Add Conflict",
			ExternalFunctionMerger.KEEP_BOTH_BUTTON_NAME);

		waitForMergeCompletion();

		ExternalManager externalManager = resultProgram.getExternalManager();
		Set<ExternalLocation> externalLocations =
			externalManager.getExternalLocations("user32.dll", "BETTY");
		assertEquals(2, externalLocations.size());
		assertHasExtAddresses(externalLocations, "1002239", "10063b4");

		Set<ExternalLocation> externalLocations2 =
			externalManager.getExternalLocations("user32.dll", "BARNEY");
		assertEquals(2, externalLocations2.size());
		assertHasExtAddresses(externalLocations2, "77db1020", "77db1130");

	}
Test the merge of external function variables.
Ghidra/Features/Base/src/test.slow/java/ghidra/app/merge/listing/ExternalFunctionMergeManagerTest.java