I'd prefer you use wh_json:is_true/3 here, because pvt_enabled could be set to <<"true">>, which would cause your test to fail.