changed static beforeclass function