Skip to content

Commit

Permalink
Remove unused tests
Browse files Browse the repository at this point in the history
  • Loading branch information
clubby789 committed Oct 26, 2021
1 parent e489eb0 commit baae4ed
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions tests/test_core.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from pytest import raises
from hackthebox.htb import HTBClient

from hackthebox import errors
from hackthebox.htb import HTBClient


def test_login(mock_htb_client: HTBClient):
Expand All @@ -18,22 +19,11 @@ def test_otp_login():
# Wait for server thread to start
time.sleep(0.5)

with raises(errors.MissingOTPException):
HTBClient(email="[email protected]", password="password", api_base=f"http://localhost:{port}/api/v4/")
with raises(errors.IncorrectOTPException):
HTBClient(email="[email protected]", password="password", otp=555555, api_base=f"http://localhost:{port}/api/v4/")
HTBClient(email="[email protected]", password="password", otp=111111, api_base=f"http://localhost:{port}/api/v4/")


def test_incorrect_login():
with raises(errors.AuthenticationException):
HTBClient()
with raises(errors.AuthenticationException):
HTBClient(password="wrong")
with raises(errors.AuthenticationException):
HTBClient(email="[email protected]")


def test_get_own_user(mock_htb_client: HTBClient):
assert mock_htb_client.user is not None

Expand Down

0 comments on commit baae4ed

Please sign in to comment.