def METHOD_NAME(self):
    parser = JSONParser()
    # Default to strict
    for value in ['Infinity', '-Infinity', 'NaN']:
        with pytest.raises(ParseError):
            parser.parse(self.bytes(value))
    parser.strict = False
    assert parser.parse(self.bytes('Infinity')) == float('inf')
    assert parser.parse(self.bytes('-Infinity')) == float('-inf')
    assert math.isnan(parser.parse(self.bytes('NaN')))