Пример #1
0
END_TEST


START_TEST(test_Reaction_fast)
{
  Reaction_setFast(R, 1);

  fail_unless(Reaction_isSetFast(R) == 1);
  fail_unless(Reaction_getFast(R) == 1);

  Reaction_unsetFast(R);

  fail_unless(Reaction_isSetFast(R) == 0);
  fail_unless(Reaction_getFast(R) == 1);

  Reaction_setFast(R, 0);

  fail_unless(Reaction_isSetFast(R) == 1);
  fail_unless(Reaction_getFast(R) == 0);

  Reaction_unsetFast(R);

  fail_unless(Reaction_isSetFast(R) == 0);
  fail_unless(Reaction_getFast(R) == 0);
}
Пример #2
0
END_TEST


START_TEST (test_Reaction_setFast2)
{
  Reaction_t *R1 = Reaction_create(2, 4);
  int i = Reaction_unsetFast(R1);

  fail_unless( i == LIBSBML_OPERATION_SUCCESS );
  fail_unless( Reaction_getFast(R1) == 0 );
  fail_unless( !Reaction_isSetFast(R1));
}
Пример #3
0
END_TEST


START_TEST (test_Reaction_setFast1)
{
  int i = Reaction_setFast(R, 1);

  fail_unless( i == LIBSBML_OPERATION_SUCCESS );
  fail_unless( Reaction_getFast(R) == 1 );
  fail_unless( Reaction_isSetFast(R));

  i = Reaction_setFast(R, 0);

  fail_unless( i == LIBSBML_OPERATION_SUCCESS );
  fail_unless( Reaction_getFast(R) == 0 );
  fail_unless( Reaction_isSetFast(R));

  i = Reaction_unsetFast(R);

  fail_unless( i == LIBSBML_OPERATION_SUCCESS );
  fail_unless( Reaction_getFast(R) == 0 );
  fail_unless( !Reaction_isSetFast(R));
}