CFY-1848 flake8
CFY-1848 fix tests