MCPcopy Create free account
hub / github.com/angular-ui/ui-router / getMatcher

Function getMatcher

test/urlMatcherFactorySpec.ts:989–1003  ·  view source on GitHub ↗
(squash)

Source from the content-addressed store, hash-verified

987 describe('squash policy', function () {
988 const Session = { username: 'loggedinuser' };
989 function getMatcher(squash) {
990 return $umf.compile('/user/:userid/gallery/:galleryid/photo/:photoid', {
991 state: {
992 params: {
993 userid: {
994 squash: squash,
995 value: function () {
996 return Session.username;
997 },
998 },
999 galleryid: { squash: squash, value: 'favorites' },
1000 },
1001 },
1002 });
1003 }
1004
1005 it(': true should squash the default value and one slash', inject(function ($stateParams) {
1006 const m = getMatcher(true);

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected