def test_command_handle(self): """Test command assemble leaderboards.""" Command().handle() assert LeaderboardRank.objects.all().count() == 255 assert LeaderboardRank.objects.filter(leaderboard="all_all").count() == 17 assert LeaderboardRank.objects.filter(leaderboard="all_fulfilled").count() == 17 assert LeaderboardRank.objects.filter(leaderboard="all_earners").count() == 2 assert LeaderboardRank.objects.filter(leaderboard="all_payers").count() == 2 assert LeaderboardRank.objects.filter(leaderboard="all_tokens").count() == 1 assert LeaderboardRank.objects.filter(leaderboard="all_countries").count() == 3 assert LeaderboardRank.objects.filter(leaderboard="all_keywords").count() == 2
def test_handle_command(self): """Test command assemble leaderboards.""" Command().handle() assert LeaderboardRank.objects.filter().count() == 8