added guard for tests