Skip to content

Commit

Permalink
uncomment some tests for broken endpoints (misc)
Browse files Browse the repository at this point in the history
  • Loading branch information
SharpBit committed Feb 17, 2020
1 parent 3e174be commit 8f12f3c
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 12 deletions.
9 changes: 4 additions & 5 deletions tests/brawlapi/test_async.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import asynctest
import asyncio
# import datetime
import datetime
import os

import brawlstats
Expand Down Expand Up @@ -78,9 +78,9 @@ async def request():
invalid_key = 'invalid'
self.assertRaises(KeyError, request)

# async def test_get_misc(self):
# misc = await self.client.get_misc()
# self.assertEqual(misc.server_date_year, datetime.date.today().year)
async def test_get_misc(self):
misc = await self.client.get_misc()
self.assertEqual(misc.server_date_year, datetime.date.today().year)

async def test_club_search(self):
search = await self.client.search_club('Cactus Bandits')
Expand All @@ -90,7 +90,6 @@ async def test_battle_logs(self):
logs = await self.client.get_battle_logs(self.player_tag)
self.assertIsInstance(logs, BattleLog)

# Other
async def test_invalid_tag(self):
async def request():
await self.client.get_player(invalid_tag)
Expand Down
9 changes: 4 additions & 5 deletions tests/brawlapi/test_blocking.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# import datetime
import datetime
import unittest
import os
import time
Expand Down Expand Up @@ -77,9 +77,9 @@ def test_get_constants(self):
invalid_key = 'invalid'
self.assertRaises(KeyError, get_constants, invalid_key)

# def test_get_misc(self):
# misc = self.client.get_misc()
# self.assertEqual(misc.server_date_year, datetime.date.today().year)
def test_get_misc(self):
misc = self.client.get_misc()
self.assertEqual(misc.server_date_year, datetime.date.today().year)

def test_club_search(self):
search = self.client.search_club('Cactus Bandits')
Expand All @@ -89,7 +89,6 @@ def test_battle_logs(self):
logs = self.client.get_battle_logs(self.player_tag)
self.assertIsInstance(logs, BattleLog)

# Other
def test_invalid_tag(self):
get_player = self.client.get_player
invalid_tag = 'P'
Expand Down
1 change: 0 additions & 1 deletion tests/officialapi/test_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ async def test_battle_logs(self):
logs = await self.client.get_battle_logs(self.player_tag)
self.assertIsInstance(logs, BattleLog)

# Other
async def test_invalid_tag(self):
async def request():
await self.client.get_player(invalid_tag)
Expand Down
1 change: 0 additions & 1 deletion tests/officialapi/test_blocking.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ def test_battle_logs(self):
logs = self.client.get_battle_logs(self.player_tag)
self.assertIsInstance(logs, BattleLog)

# Other
def test_invalid_tag(self):
get_player = self.client.get_player
invalid_tag = 'P'
Expand Down

0 comments on commit 8f12f3c

Please sign in to comment.