= commited on
Commit
d25f40f
·
1 Parent(s): 564d4a0

added basic tests

Browse files
Files changed (1) hide show
  1. tests/test_deep_translator.py +6 -6
tests/test_deep_translator.py CHANGED
@@ -3,7 +3,7 @@
3
  """Tests for `deep_translator` package."""
4
 
5
  import pytest
6
-
7
 
8
  @pytest.fixture
9
  def response():
@@ -12,11 +12,11 @@ def response():
12
  See more at: http://doc.pytest.org/en/latest/fixture.html
13
  """
14
  pass
15
- # with pytest.raises(LanguageNotSupportedException):
16
- # GoogleTranslator(source="", target="")
17
- #
18
- # with pytest.raises(LanguageNotSupportedException):
19
- # GoogleTranslator(source="auto", target="nothing")
20
 
21
 
22
  def test_content(response):
 
3
  """Tests for `deep_translator` package."""
4
 
5
  import pytest
6
+ from deep_translator import exceptions, GoogleTranslator
7
 
8
  @pytest.fixture
9
  def response():
 
12
  See more at: http://doc.pytest.org/en/latest/fixture.html
13
  """
14
  pass
15
+ with pytest.raises(exceptions.LanguageNotSupportedException):
16
+ GoogleTranslator(source="", target="")
17
+
18
+ with pytest.raises(exceptions.LanguageNotSupportedException):
19
+ GoogleTranslator(source="auto", target="nothing")
20
 
21
 
22
  def test_content(response):