Add pattern rule and test case.
Fixed type=number.