This repository was archived by the owner on Apr 26, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ Add some type hints to tests files.
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ def setUp(self):
3939 # NB: `signedjson` expects `nacl.signing.SigningKey` instances which have been
4040 # monkeypatched to include new `alg` and `version` attributes. This is captured
4141 # by the `signedjson.types.SigningKey` protocol.
42- self .signing_key : signedjson .types .SigningKey = nacl .signing .SigningKey (
42+ self .signing_key : signedjson .types .SigningKey = nacl .signing .SigningKey ( # type: ignore[assignment]
4343 SIGNING_KEY_SEED
4444 )
4545 self .signing_key .alg = KEY_ALG
Original file line number Diff line number Diff line change @@ -60,7 +60,9 @@ def test_parse_json_value(self):
6060 with self .assertRaises (SynapseError ):
6161 parse_json_value_from_request (make_request (b"" ))
6262
63- result3 = parse_json_value_from_request (make_request (b"" ), allow_empty_body = True )
63+ result3 = parse_json_value_from_request (
64+ make_request (b"" ), allow_empty_body = True
65+ )
6466 self .assertIsNone (result3 )
6567
6668 # Invalid UTF-8.
Original file line number Diff line number Diff line change 3434try :
3535 import jaeger_client
3636except ImportError :
37- jaeger_client = None
37+ jaeger_client = None # type: ignore
3838
3939from tests .unittest import TestCase
4040
@@ -43,7 +43,7 @@ class LogContextScopeManagerTestCase(TestCase):
4343 if LogContextScopeManager is None :
4444 skip = "Requires opentracing" # type: ignore[unreachable]
4545 if jaeger_client is None :
46- skip = "Requires jaeger_client"
46+ skip = "Requires jaeger_client" # type: ignore[unreachable]
4747
4848 def setUp (self ) -> None :
4949 # since this is a unit test, we don't really want to mess around with the
You can’t perform that action at this time.
0 commit comments