implement BDIF operation

Move the boilerplate test runner code to test templates module so the
operation tests can be pure tables.
implement WDIF and TDIF operation
implement ODIF operation