metron-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ottobackwards <...@git.apache.org>
Subject [GitHub] metron issue #899: METRON-1405: Add Boyer-Moore majority vote algorithm to S...
Date Tue, 16 Jan 2018 18:32:59 GMT
Github user ottobackwards commented on the issue:

    https://github.com/apache/metron/pull/899
  
    This tests fails, I think something is wrong.
    
    ```java
     @Test
      public void boyerMoore_calculates_plurality_from_list_of_mixed_objects_o() throws Exception
{
        List<Object> items = Arrays.asList(1,1,1,1, "orange", "orange", "jello", "jello",
"jello");
        BoyerMooreState state = (BoyerMooreState) new BoyerMooreAdd().apply(Arrays.asList(null,
items));
        Assert.assertThat(new BoyerMoorePlurality().apply(ImmutableList.of(state)), CoreMatchers.equalTo(1));
      }
    ```



---

Mime
View raw message