REVIEW: [NX-501] Token Pattern Parser

JIRA: https://issues.sonatype.org/browse/NX-501
Minor: I prefer `(tokens.entrySet(), hasSize(2))` over this above as in case of failure you know how much elements actually