Added filter and some basic unit tests.