@@ -23,7 +23,7 @@ def before_each(self, context):
2323 self .intercom .app_id = 'abc123'
2424 self .intercom .app_api_key = 'super-secret-key'
2525
26- def it_raises_argumenterror_if_no_app_id_or_app_api_key_specified (self ):
26+ def it_raises_argumenterror_if_no_app_id_or_app_api_key_specified (self ): # noqa
2727 self .intercom .app_id = None
2828 self .intercom .app_api_key = None
2929 with expect .to_raise_error (intercom .ArgumentError ):
@@ -58,21 +58,21 @@ def it_allows_overriding_of_the_endpoint_and_protocol(self):
5858
5959 def it_prefers_endpoints (self ):
6060 self .intercom .endpoint = "https://localhost:7654"
61- expect (self .intercom .target_base_url ) == "https://abc123:super-secret-key@localhost:7654"
61+ expect (self .intercom .target_base_url ) == "https://abc123:super-secret-key@localhost:7654" # noqa
6262
6363 # turn off the shuffle
6464 with mock .patch ("random.shuffle" ) as mock_shuffle :
65- mock_shuffle .return_value = ["http://example.com" , "https://localhost:7654" ]
66- self .intercom .endpoints = ["http://example.com" , "https://localhost:7654" ]
65+ mock_shuffle .return_value = ["http://example.com" , "https://localhost:7654" ] # noqa
66+ self .intercom .endpoints = ["http://example.com" , "https://localhost:7654" ] # noqa
6767 expect (self .intercom .target_base_url ) == \
6868 'http://abc123:super-secret-key@example.com'
6969
7070 def it_has_endpoints (self ):
7171 expect (self .intercom .endpoints ) == ["https://api.intercom.io" ]
72- self .intercom .endpoints = ["http://example.com" ,"https://localhost:7654" ]
73- expect (self .intercom .endpoints ) == ["http://example.com" ,"https://localhost:7654" ]
72+ self .intercom .endpoints = ["http://example.com" , "https://localhost:7654" ] # noqa
73+ expect (self .intercom .endpoints ) == ["http://example.com" , "https://localhost:7654" ] # noqa
7474
75- def it_should_randomize_endpoints_if_last_checked_endpoint_is_gt_5_minutes_ago (self ):
75+ def it_should_randomize_endpoints_if_last_checked_endpoint_is_gt_5_minutes_ago (self ): # noqa
7676 now = time .mktime (datetime .utcnow ().timetuple ())
7777 self .intercom ._endpoint_randomized_at = now
7878 self .intercom .endpoints = ["http://alternative" ]
@@ -82,4 +82,3 @@ def it_should_randomize_endpoints_if_last_checked_endpoint_is_gt_5_minutes_ago(s
8282 expect (self .intercom .current_endpoint ) == "http://start"
8383 self .intercom ._endpoint_randomized_at = now - 360
8484 expect (self .intercom .current_endpoint ) == "http://alternative"
85-
0 commit comments