use of org.apache.tools.ant.types.resources.ImmutableResourceException in project ant by apache.
the class ResourceOutputTest method testpropertyoutput2.
@Test
public void testpropertyoutput2() throws IOException {
project.setNewProperty("bar", "bar");
PropertyResource r = new PropertyResource(project, "bar");
try {
testoutput(r);
fail("should have caught ImmutableResourceException");
} catch (ImmutableResourceException e) {
// TODO assert exception message
}
assertEquals("bar", project.getProperty("bar"));
}
use of org.apache.tools.ant.types.resources.ImmutableResourceException in project ant by apache.
the class ResourceOutputTest method teststringoutput2.
@Test
public void teststringoutput2() throws IOException {
StringResource r = new StringResource("bar");
try {
testoutput(r);
fail("should have caught ImmutableResourceException");
} catch (ImmutableResourceException e) {
// TODO assert exception message
}
assertEquals("bar", r.getValue());
}
Aggregations