actually it looks like `as_test` is no longer needed  and this if else is totally redundant. should just kill it?