Trainer.test() returns type error while loading model after upgrading from pl 0.76 to 0.8 and 0.82dev
🐛 Bug
I am running a Transformer model with a custom data set. Everything worked fine with v0.76, except for early stopping. However after upgrading to v0.8+ Trainer.test() would return type error while loading model (expected int but got dict). I have tried two different datasets with the same model which returned same results. I have downgraded back to v0.76 and Trainer.test() was able to run, but earlystopping would not work properly.

Code sample
trainer.test()

Expected behavior
Trainer.test() should run model.test_step without error