// Path: src/test/java/com/metamx/emitter/core/MapEvent.java
// @JsonSerialize(converter = MapEvent.MapEventConverter.class)
// public final class MapEvent implements Event
// {
//   private final Map<String, Object> map;
// 
//   public MapEvent(Map<String, Object> map)
//   {
//     this.map = map;
//   }
// 
//   @Override
//   public Map<String, Object> toMap()
//   {
//     return map;
//   }
// 
//   @Override
//   public String getFeed()
//   {
//     return (String) map.get("feed");
//   }
// 
//   @Override
//   public DateTime getCreatedTime()
//   {
//     return (DateTime) map.get("createdTime");
//   }
// 
//   @Override
//   public boolean isSafeToBuffer()
//   {
//     return map.containsKey("isSafeToBuffer");
//   }
// 
//   public static class MapEventConverter extends StdConverter<MapEvent, Map<String, Object>>
//   {
//     @Override
//     public Map<String, Object> convert(MapEvent value)
//     {
//       return value.toMap();
//     }
//   }
// }


import com.google.common.collect.ImmutableMap;
import com.metamx.emitter.core.MapEvent;
import org.junit.Assert;
import org.junit.Test;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
package com.metamx.emitter.core.filter;



public class MultiBWListEventFilterTest
{
  @Test
  public void whiteListTest()
  {
    final MultiBWListEventFilter baseEventFilter = new MultiBWListEventFilter(
        ImmutableMap.of(
            "A", Collections.singletonList("A1"),
            "B", Arrays.asList("B1", "B2"),
            "C", new ArrayList<>()
        ),
        ImmutableMap.of()
    );
    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("A", "A1"))));
    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("A", "A2"))));

    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("B", "B1"))));
    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("B", "B2"))));
    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("B", "B3"))));

    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("C", "C1"))));
    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("C", "C2"))));

    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("D", "D1"))));
  }

  @Test
  public void blackListTest()
  {
    final MultiBWListEventFilter baseEventFilter = new MultiBWListEventFilter(
        ImmutableMap.of(),
// Path: src/test/java/com/metamx/emitter/core/MapEvent.java
// @JsonSerialize(converter = MapEvent.MapEventConverter.class)
// public final class MapEvent implements Event
// {
//   private final Map<String, Object> map;
// 
//   public MapEvent(Map<String, Object> map)
//   {
//     this.map = map;
//   }
// 
//   @Override
//   public Map<String, Object> toMap()
//   {
//     return map;
//   }
// 
//   @Override
//   public String getFeed()
//   {
//     return (String) map.get("feed");
//   }
// 
//   @Override
//   public DateTime getCreatedTime()
//   {
//     return (DateTime) map.get("createdTime");
//   }
// 
//   @Override
//   public boolean isSafeToBuffer()
//   {
//     return map.containsKey("isSafeToBuffer");
//   }
// 
//   public static class MapEventConverter extends StdConverter<MapEvent, Map<String, Object>>
//   {
//     @Override
//     public Map<String, Object> convert(MapEvent value)
//     {
//       return value.toMap();
//     }
//   }
// }


// Path: src/test/java/com/metamx/emitter/core/filter/MultiBWListEventFilterTest.java
import com.google.common.collect.ImmutableMap;
import com.metamx.emitter.core.MapEvent;
import org.junit.Assert;
import org.junit.Test;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;

package com.metamx.emitter.core.filter;



public class MultiBWListEventFilterTest
{
  @Test
  public void whiteListTest()
  {
    final MultiBWListEventFilter baseEventFilter = new MultiBWListEventFilter(
        ImmutableMap.of(
            "A", Collections.singletonList("A1"),
            "B", Arrays.asList("B1", "B2"),
            "C", new ArrayList<>()
        ),
        ImmutableMap.of()
    );
    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("A", "A1"))));
    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("A", "A2"))));

    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("B", "B1"))));
    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("B", "B2"))));
    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("B", "B3"))));

    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("C", "C1"))));
    Assert.assertTrue(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("C", "C2"))));

    Assert.assertFalse(baseEventFilter.isNotWhiteListed(new MapEvent(ImmutableMap.of("D", "D1"))));
  }

  @Test
  public void blackListTest()
  {
    final MultiBWListEventFilter baseEventFilter = new MultiBWListEventFilter(
        ImmutableMap.of(),
        ImmutableMap.of(