Examples of withRole()


Examples of mondrian.test.TestContext.withRole()

        final TestContext context =
            TestContext.instance().withSchema(schema);

        // The filter condition does not require a join to the fact table.
        assertQuerySql(context, query, patterns);
        assertQuerySql(context.withRole("Role1"), query, patterns);

        // in a non-empty context where a role is in effect, the query
        // will pessimistically join the fact table and apply the
        // constraint, since the filter condition could be influenced by
        // role limitations.
View Full Code Here

Examples of mondrian.test.TestContext.withRole()

        // in a non-empty context where a role is in effect, the query
        // will pessimistically join the fact table and apply the
        // constraint, since the filter condition could be influenced by
        // role limitations.
        assertQuerySql(
            context.withRole("Role1"), nonEmptyQuery, patternsWithFactJoin);
    }

    /**
     * Test case for
     * <a href="http://jira.pentaho.com/browse/MONDRIAN-1133">MONDRIAN-1133</a>
View Full Code Here

Examples of mondrian.test.TestContext.withRole()

        final TestContext context =
            TestContext.instance().withSchema(schema);

        // The filter condition does not require a join to the fact table.
        assertQuerySql(context, query, patterns);
        assertQuerySql(context.withRole("Role1"), query, patterns);

        // in a non-empty context where a role is in effect, the query
        // will pessimistically join the fact table and apply the
        // constraint, since the filter condition could be influenced by
        // role limitations.
View Full Code Here

Examples of mondrian.test.TestContext.withRole()

        // in a non-empty context where a role is in effect, the query
        // will pessimistically join the fact table and apply the
        // constraint, since the filter condition could be influenced by
        // role limitations.
        assertQuerySql(
            context.withRole("Role1"), nonEmptyQuery, patternsWithFactJoin);
    }


    /**
     * Native CrossJoin with a ranged slicer.
View Full Code Here

Examples of mondrian.test.TestContext.withRole()

        TestContext testContext = TestContext.instance().createSubstitutingCube(
            "Sales",
            null,
            nonAccessibleMember
            + accessibleMember);
        return testContext.withRole("California manager");
    }

    private void assertCalculatedMemberExists(
        String[] expectedCalculatedMembers,
        List<Member> calculatedMembers)
View Full Code Here

Examples of mondrian.test.TestContext.withRole()

                + "    </CubeGrant>\n"
                + "  </SchemaGrant>\n"
                + "</Role>\n");
        final String mdx =
            "select {[Customers].[USA], [Customers].[USA].[OR], [Customers].[USA].[WA]} on columns, {[Measures].[Customer Count]} on rows from [Sales]";
        context
            .withRole("Role1")
                .assertQueryReturns(
                    mdx,
                    "Axis #0:\n"
                    + "{}\n"
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.