@Test
	public void testSetDefaultSettings() throws Exception {

		DataType dt = StringDataType.dataType;

		Settings defaultSettings = dt.getDefaultSettings();

		// immutable warnings expected
		defaultSettings.setString(STRING_SETTING_NAME, "red");
		defaultSettings.setLong(LONG_SETTING_NAME, 10);

		assertNull(defaultSettings.getString(STRING_SETTING_NAME));
		assertNull(defaultSettings.getLong(LONG_SETTING_NAME));

		// May modify byte default settings after resolve
		dt = dataMgr.resolve(dt, null);

		defaultSettings = dt.getDefaultSettings();
		defaultSettings.setString(STRING_SETTING_NAME, "red");
		defaultSettings.setLong(LONG_SETTING_NAME, 10);

		assertEquals("red", defaultSettings.getString(STRING_SETTING_NAME));
		Long lv = defaultSettings.getLong(LONG_SETTING_NAME);
		assertNotNull(lv);
		assertEquals(10, lv.longValue());

		defaultSettings.setValue(LONG_SETTING_NAME, 20L);
		Object obj = defaultSettings.getValue(LONG_SETTING_NAME);
		assertTrue(obj instanceof Long);
		assertEquals(20, ((Long) obj).longValue());
	}
Test setting default and instance settings on Data.
Ghidra/Features/Base/src/test.slow/java/ghidra/program/database/data/SettingsTest.java