You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (JIRA)" <ji...@apache.org> on 2018/08/19 18:15:00 UTC
[jira] [Commented] (CALCITE-2480) calcite.util.NameSet does not
work
[ https://issues.apache.org/jira/browse/CALCITE-2480?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16585236#comment-16585236 ]
Julian Hyde commented on CALCITE-2480:
--------------------------------------
I'm working on this.
> calcite.util.NameSet does not work
> ----------------------------------
>
> Key: CALCITE-2480
> URL: https://issues.apache.org/jira/browse/CALCITE-2480
> Project: Calcite
> Issue Type: Bug
> Components: core
> Reporter: Vladimir Sitnikov
> Assignee: Vladimir Sitnikov
> Priority: Major
>
> {code:java} @Test public void testNameSetContains() {
> final NameSet names = new NameSet();
> names.add("COUNT");
> names.add("COVAR_POP");
> assertThat(names.contains("count", true), is(false));
> assertNsContains(names, "count", false, true);
> }
> private void assertNsContains(NameSet names, String item, boolean caseSensitive, boolean result) {
> assertEquals(names + ", contains(" + item + (caseSensitive ? ", caseSensitive" : "")
> + ")",
> result, names.contains(item, caseSensitive));
> }{code}
> Output
> {noformat}java.lang.AssertionError: [COUNT, COVAR_POP], contains(count)
> Expected :true
> Actual :false{noformat}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)