Skip to content

Instantly share code, notes, and snippets.

@jalada
Created March 22, 2012 09:58
Show Gist options
  • Save jalada/2157479 to your computer and use it in GitHub Desktop.
Save jalada/2157479 to your computer and use it in GitHub Desktop.
jalada@aer Development/shaed-temp » nodeunit test/
router_test
✔ Router - translateUrl function - translates a path with a regex
✔ Router - translateUrl function - translates a path to a hardcoded URL
✔ Router - translateUrl function - can translate a regexp involving a query string
✔ Router - translateUrl function - returns false when the regexp doesn't match
✔ Router - translateUrl function - replaces multiple variables
✔ Router - translateUrl function - replaces the same variable across entire destination URL
✔ Router - translateUrl function - returns false if parts of regexp did not match
OK: 7 assertions (20ms)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment