Datalayer tests.
Added missing equality operators.
Added some more unit tests.
More tests and fixes.