Added test for sizeFormat filter and a little of refactoring of this filter