move the FrTest module into its own file

plus some other minor junk

Change-Id: I27617a3bd08f5e6c1b73a809243428e036e38f64