コード例 #1
0
 @Test
 public void shouldCreateIntegerValue() throws Exception {
   final int value = 5;
   final Value<Integer> term =
       TransformationFactory.createValue(OperationTestConstants.INT_DESCRIPTOR, value);
   assertThat(term, is(notNullValue()));
   assertThat(term.get(), is(value));
   assertThat(term.descriptor(), is(OperationTestConstants.INT_DESCRIPTOR));
 }
コード例 #2
0
 @Test
 public void shouldCreateLongValue() throws Exception {
   final long value = 5;
   final Value<Long> term =
       TransformationFactory.createValue(OperationTestConstants.LONG_DESCRIPTOR, value);
   assertThat(term, is(notNullValue()));
   assertThat(term.get(), is(value));
   assertThat(term.descriptor(), is(OperationTestConstants.LONG_DESCRIPTOR));
 }
コード例 #3
0
 @Test
 public void shouldCreateDoubleValue() throws Exception {
   final double value = 5;
   final Value<Double> term =
       TransformationFactory.createValue(OperationTestConstants.DOUBLE_DESCRIPTOR, value);
   assertThat(term, is(notNullValue()));
   assertThat(term.get(), is(value));
   assertThat(term.descriptor(), is(OperationTestConstants.DOUBLE_DESCRIPTOR));
 }
コード例 #4
0
ファイル: IncrementTest.java プロジェクト: jpav/chrysalix
 @Test
 public void shouldIncrement() throws ChrysalixException {
   this.operation.addInput(ID, INT_TERM);
   assertThat(this.operation.get(), is(INT_TERM.get().intValue() + 1));
 }