Boost logo

Boost :

Subject: [boost] [test] Really deactivate test
From: Florian Lindner (mailinglists_at_[hidden])
Date: 2016-12-12 03:24:32


Hello,

I need to conditionally decativate tests and use a custom decorator for that, like that:

  virtual void apply(bt::test_unit& tu)
  {
    [...]
    if (std::find(_ranks.begin(), _ranks.end(), rank) == _ranks.end()) {
      std::cout << rank << " Disable, because of rank, test: " << tu.full_name() << std::endl;
      tu.p_default_status.value = bt::test_unit::RS_DISABLED;
      return;
    }
  }

(i'm happy to provide full source code, if anyone is interested)
As you can see it's deativated on some MPI ranks only.

However, if a user uses -t "testname" it is activated again.

Is there a way to really deactivate the test? Or delete it from the test tree?

Thanks,
Florian


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk