pat_advanced.t: fix two tests

If two pieces of code are executed to see if they produce exactly the
same warning, the scalar holding the warning needs to be cleared in
between, otherwise the second test is useless if the first one passes
and the second piece of code doesn’t warn.