use of com.thoughtworks.go.config.materials.AbstractMaterial in project gocd by gocd.
the class AbstractMaterialTest method shouldReturnFullNameIfTheLengthIsLessThanGivenThreshold.
@Test
public void shouldReturnFullNameIfTheLengthIsLessThanGivenThreshold() throws Exception {
AbstractMaterial material = new TestMaterial("foo_bar_baz_quuz_ban");
assertThat(material.getTruncatedDisplayName()).isEqualTo("foo_bar_baz_quuz_ban");
}
use of com.thoughtworks.go.config.materials.AbstractMaterial in project gocd by gocd.
the class AbstractMaterialTest method shouldReturnTruncatedNameIfTheLengthIsGreaterThanGivenThreshold.
@Test
public void shouldReturnTruncatedNameIfTheLengthIsGreaterThanGivenThreshold() throws Exception {
AbstractMaterial material = new TestMaterial("foo_bar_baz_quuz_ban_pavan");
assertThat(material.getTruncatedDisplayName()).isEqualTo("foo_bar_ba..._ban_pavan");
}
use of com.thoughtworks.go.config.materials.AbstractMaterial in project gocd by gocd.
the class AbstractMaterialTest method shouldNotIgnoreForSchedulingByDefault_sinceItOnlyAppliesToDependencyMaterial.
@Test
public void shouldNotIgnoreForSchedulingByDefault_sinceItOnlyAppliesToDependencyMaterial() {
AbstractMaterial material = new TestMaterial("salty_sumatran_rhinoceros");
assertThat(material.ignoreForScheduling()).isFalse();
}
Aggregations