void
PropertyTest :: testIteration()
{
  LoggerStack stack;
  stack.setGlobalLevel(Logger::LEVEL_WARN, false);

  RefPointer<Configurable> c = Demuxer::make();

  int32_t numProperties = c->getNumProperties();
  TSM_ASSERT("", numProperties > 0);

  for(int32_t i = 0; i < numProperties; i++)
  {
    RefPointer <Property> property =  c->getPropertyMetaData(i);
    const char* name = property->getName();
    VS_LOG_DEBUG("Name: %s", name);
    VS_LOG_DEBUG("Description: %s", property->getHelp());
    VS_LOG_DEBUG("Default: %lld", property->getDefault());
    if (strcmp(name, "cryptokey")==0)
      continue;
    VS_LOG_DEBUG("Current value (boolean) : %d", (int32_t)c->getPropertyAsBoolean(name));
    VS_LOG_DEBUG("Current value (double)  : %f", c->getPropertyAsDouble(name));
    VS_LOG_DEBUG("Current value (long)    : %lld", c->getPropertyAsLong(name));
    RefPointer<Rational> rational = c->getPropertyAsRational(name);
    VS_LOG_DEBUG("Current value (rational): %f", rational->getValue());
    char* value=c->getPropertyAsString(name);
    VS_LOG_DEBUG("Current value (string)  : %s", value);
    if (value) free(value);
  }
}
void
PropertyTest :: testCreation()
{
  LoggerStack stack;
  stack.setGlobalLevel(Logger::LEVEL_WARN, false);
  RefPointer<Configurable> c = Demuxer::make();
  RefPointer<Property> property =  c->getPropertyMetaData("packetsize");
  VS_LOG_DEBUG("Name: %s", property->getName());
  VS_LOG_DEBUG("Description: %s", property->getHelp());
  TSM_ASSERT("should exist", property);
}