Fix: options array is optional in add_rule
More test cases