added rules, enums and tests