Reorganise test imports and gofmt