Skip to content

Instantly share code, notes, and snippets.

@3rd-Eden
Created December 16, 2014 21:58
Show Gist options
  • Select an option

  • Save 3rd-Eden/329b18e6e84bc9c5cea8 to your computer and use it in GitHub Desktop.

Select an option

Save 3rd-Eden/329b18e6e84bc9c5cea8 to your computer and use it in GitHub Desktop.

Revisions

  1. 3rd-Eden created this gist Dec 16, 2014.
    1 change: 1 addition & 0 deletions failing.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1 @@
    /^(?:(?:(([^:\/#\?]+:)?(?:(?:\/\/)(?:(?:(?:([^:@\/#\?]+)(?:\:([^:@\/#\?]*))?)@)?(([^:\/#\?\]\[]+|\[[^\/\]@#?]+\])(?:\:([0-9]+))?))?)?)?((?:\/?(?:[^\/\?#]+\/+)*)(?:[^\?#]*)))?(\?[^#]+)?)(#.*)?/.exec('https://www.mozilla.org/en-US/firefox/34.0/whatsnew/?oldversion=33.1')
    4 changes: 4 additions & 0 deletions passing
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    var r = /^(?:(?:(([^:\/#\?]+:)?(?:(?:\/\/)(?:(?:(?:([^:@\/#\?]+)(?:\:([^:@\/#\?]*))?)@)?(([^:\/#\?\]\[]+|\[[^\/\]@#?]+\])(?:\:([0-9]+))?))?)?)?((?:\/?(?:[^\/\?#]+\/+)*)(?:[^\?#]*)))?(\?[^#]+)?)(#.*)?/;

    r.test('');
    r.exec('https://www.mozilla.org/en-US/firefox/34.0/whatsnew/?oldversion=33.1');