Changed test branches from "test/..." to "tests/..."

+ small refactoring