Test CEs that immediately follow a not CE are automatically moved by CLIPS behind the first pattern CE that precedes the not CE. For example, the following rule
(defrule example (a ?x) (not (b ?x)) (test (> ?x 5)) =>)
would be changed as follows.
(defrule example (a ?x) (test (> ?x 5)) (not (b ?x)) =>)