wrote a test for the filter logic