Tested the rules entry code by injecting and printing rules. Need more tests.

Change-Id: I8479518b766a3bbfcfc06afc63731e8c244e277a