Mentions légales du service

Skip to content
Snippets Groups Projects
  • Adam Powers's avatar
    dbbd94d5
    Fixes s3u/JSONPath#49 - parsing error when bracket paths contain dot · dbbd94d5
    Adam Powers authored
    Added six new tests for various path formats:
    $.store.book[*].author
    $['store']['book'][*]['author']
    $[store][book][*][author]
    $.store.book[*]['author']
    $['store']['book'][*]['application/vnd.wordperfect']
    $.store.book[*]['vnd.wordperfect']
    
    Prior to fixing a regular expression in the _normalize() function, the
    last two tests would fail due to the '.' in the bracket path
    'vnd.wordperfect'. This is fixed by adding a negative forward
    lookahead (?![^\[]*\]) to the regular expression identifying '.'. The
    new negative forward lookahead assumes that any '.' before a '[' is
    okay, but any '.' before a ']' must be inside a bracket set and should
    be ignored.
    dbbd94d5
    History
    Fixes s3u/JSONPath#49 - parsing error when bracket paths contain dot
    Adam Powers authored
    Added six new tests for various path formats:
    $.store.book[*].author
    $['store']['book'][*]['author']
    $[store][book][*][author]
    $.store.book[*]['author']
    $['store']['book'][*]['application/vnd.wordperfect']
    $.store.book[*]['vnd.wordperfect']
    
    Prior to fixing a regular expression in the _normalize() function, the
    last two tests would fail due to the '.' in the bracket path
    'vnd.wordperfect'. This is fixed by adding a negative forward
    lookahead (?![^\[]*\]) to the regular expression identifying '.'. The
    new negative forward lookahead assumes that any '.' before a '[' is
    okay, but any '.' before a ']' must be inside a bracket set and should
    be ignored.