adheres_to_policy improvements

refs CNVS-11425

 * be more strict about the DSL
 * store policies so that we can avoid linear searches for
   an applicable condition block

Change-Id: I68f6414b396e1cb16d744d0719cdd6aa86085784
Reviewed-on: https://gerrit.instructure.com/36222
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Nick Cloward <ncloward@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>