test: check assigned value instead of checking not raised