Add GFI self-test

This works, but you may want to tweak it somewhat so that everything fits properly.