void () { assertEmpty(getArtifacts()); final long count = getModificationCount(); final ModifiableArtifactModel model = getArtifactManager().createModifiableModel(); final ModifiableArtifact artifact = model.addArtifact("new art", PlainArtifactType.getInstance()); artifact.setBuildOnMake(true); artifact.setOutputPath("/myout"); artifact.setName("xxx"); final MyArtifactListener listener = subscribe(); assertEmpty(getArtifacts()); commit(model); final Artifact newArt = assertOneElement(getArtifacts()); assertEquals("xxx", newArt.getName()); assertTrue(newArt.isBuildOnMake()); assertEquals("/myout", newArt.getOutputPath()); assertEquals("added:xxx;", listener.clearMessages()); assertTrue(getModificationCount() > count); }