In batches test @total was assigned but not used. Use it in tests instead of Post.count
Merge pull request #10702 from divineforest/use-total-in-batches-test

Use @total variable created in the setup of batches tests instead of counting again.