Recognize jQuery >= 1.10.0

jQuery recently passed 1.10, but the vendor regexp assumed each
component of the version number would be only one digit.  Allow
multiple digits for the minor and micro versions.
This commit is contained in:
Austin Clements
2013-10-11 21:21:43 -04:00
parent c7933537b1
commit 5232a45d1f
2 changed files with 3 additions and 1 deletions

View File

@@ -37,7 +37,7 @@
# jQuery
- (^|/)jquery([^.]*)(\.min)?\.js$
- (^|/)jquery\-\d\.\d(\.\d)?(\.min)?\.js$
- (^|/)jquery\-\d\.\d+(\.\d+)?(\.min)?\.js$
# jQuery UI
- (^|/)jquery\-ui(\-\d\.\d+(\.\d+)?)?(\.\w+)?(\.min)?\.(js|css)$

View File

@@ -236,6 +236,8 @@ class TestBlob < Test::Unit::TestCase
assert blob("public/javascripts/jquery-1.5.2.js").vendored?
assert blob("public/javascripts/jquery-1.6.1.js").vendored?
assert blob("public/javascripts/jquery-1.6.1.min.js").vendored?
assert blob("public/javascripts/jquery-1.10.1.js").vendored?
assert blob("public/javascripts/jquery-1.10.1.min.js").vendored?
assert !blob("public/javascripts/jquery.github.menu.js").vendored?
# jQuery UI