@Test
    void testRemoveMatrixVariables() {
        assertThat(removeMatrixVariables("/foo")).isEqualTo("/foo");
        assertThat(removeMatrixVariables("/foo;")).isEqualTo("/foo");
        assertThat(removeMatrixVariables("/foo/")).isEqualTo("/foo/");
        assertThat(removeMatrixVariables("/foo/bar")).isEqualTo("/foo/bar");
        assertThat(removeMatrixVariables("/foo/bar;")).isEqualTo("/foo/bar");
        assertThat(removeMatrixVariables("/foo/bar/")).isEqualTo("/foo/bar/");
        assertThat(removeMatrixVariables("/foo;/bar")).isEqualTo("/foo/bar");
        assertThat(removeMatrixVariables("/foo;/bar;")).isEqualTo("/foo/bar");
        assertThat(removeMatrixVariables("/foo;/bar/")).isEqualTo("/foo/bar/");
        assertThat(removeMatrixVariables("/foo;a=b/bar")).isEqualTo("/foo/bar");
        assertThat(removeMatrixVariables("/foo;a=b/bar;")).isEqualTo("/foo/bar");
        assertThat(removeMatrixVariables("/foo;a=b/bar/")).isEqualTo("/foo/bar/");
        assertThat(removeMatrixVariables("/foo;a=b/bar/baz")).isEqualTo("/foo/bar/baz");
        assertThat(removeMatrixVariables("/foo;a=b/bar/baz;")).isEqualTo("/foo/bar/baz");
        assertThat(removeMatrixVariables("/foo;a=b/bar/baz/")).isEqualTo("/foo/bar/baz/");
        assertThat(removeMatrixVariables("/foo;a=b/bar;/baz")).isEqualTo("/foo/bar/baz");
        assertThat(removeMatrixVariables("/foo;a=b/bar;/baz;")).isEqualTo("/foo/bar/baz");
        assertThat(removeMatrixVariables("/foo;a=b/bar;/baz/")).isEqualTo("/foo/bar/baz/");
        assertThat(removeMatrixVariables("/foo;a=b/bar;c=d/baz")).isEqualTo("/foo/bar/baz");
        assertThat(removeMatrixVariables("/foo;a=b/bar;c=d/baz;")).isEqualTo("/foo/bar/baz");
        assertThat(removeMatrixVariables("/foo;a=b/bar;c=d/baz/")).isEqualTo("/foo/bar/baz/");

        // Invalid
        assertThat(removeMatrixVariables("/;a=b")).isNull();
        assertThat(removeMatrixVariables("/prefix/;a=b")).isNull();
    }
{@link RequestTarget} treats the first `=` in a query parameter as `/` internally to simplify
the detection the logic. This test makes sure the `=` appeared later is not treated as `/`.
core/src/test/java/com/linecorp/armeria/internal/common/DefaultRequestTargetTest.java