Editrule

fixed bugs in rule editing.  sped up tests