test onlyif and unless joint state