@Override
    public KarateProtocol protocol() {
        KarateProtocol protocol = new KarateProtocol(uriPatterns);
        if (nameResolver != null) {
            protocol.nameResolver_$eq((req, sr) -> nameResolver.apply(req, sr));                
        }
        protocol.runner_$eq(runner);
        return protocol;
    }
@Test
    void uriPatterns() {

        KarateProtocol protocol = KarateDsl.karateProtocol(
            KarateDsl.uri("foo").nil(),
            KarateDsl.uri("bar").pauseFor("get", 110, "post", 220)  
        ).protocol();        

        assertEquals(110, protocol.pauseFor("bar", "get"));
        assertEquals(220, protocol.pauseFor("bar", "post"));
        assertEquals(0, protocol.pauseFor("bar", "put"));
        assertEquals(0, protocol.pauseFor("foo", "get"));
        assertEquals(0, protocol.pauseFor("foobar", "get"));

        assertTrue(protocol.pathMatches("/foo").isDefined());
        assertTrue(protocol.pathMatches("/bar").isDefined());
        assertFalse(protocol.pathMatches("/foobar").isDefined());

    }