module: add unit test for MatchPathMajor, CheckPathMajor

Requested in CL 201497. The corresponding change will be made there
after this is merged.

Change-Id: I0726c475a34a5959e5b43f126e6bf03815686385
Reviewed-on: https://go-review.googlesource.com/c/mod/+/201517
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2 files changed