Fix `Transaction.isNoOp` test

Certain operations can emit `retainMetadata` as well as `retain`, and
still be no-ops.  Add a test case to prove it.

Change-Id: Ie01d917b83e9c8b486ac0539ae1b2c6dea9e18d1
Merge "Fix `Transaction.isNoOp` test"