clearIfNotMatch with testMask using pattern