-
Notifications
You must be signed in to change notification settings - Fork 566
Add explicit type declarations #482
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
32cd6bf
Fixed mypy warning: touch_action.py
ki4070ma a5b94ed
Fixed mypy warning: multi_action.py
ki4070ma a29821c
Fixed mypy warning: extensions/android
ki4070ma 160f334
Fixed mypy warning: extensions/search_context
ki4070ma 01506da
Updated
ki4070ma bb21500
Revert some changes to run unit test
ki4070ma f8bd382
Review comments
ki4070ma 88776fa
Updates
ki4070ma dde7ac4
Updates
ki4070ma a3ae246
Add mypy check to ci.sh
ki4070ma f39e41c
Add mypy to Pipfile
ki4070ma 0f0f1f9
Updates
ki4070ma 3d7f609
Update README
ki4070ma c2fb780
Revert unexpected changes
ki4070ma 809036a
Updates Dict
ki4070ma 52069f9
Revert unexpected changes
ki4070ma 4af6cb3
Updates
ki4070ma 24e9bd9
Review comments
ki4070ma 561d9f0
Review comments
ki4070ma 91a26a4
tweak
ki4070ma ad0fe09
Restore and modify changes
ki4070ma a09eba8
Fix wrong return type
ki4070ma e77e67e
Add comments
ki4070ma edecdd7
Revert unexpected changes
ki4070ma a7c2b43
Fix mypy error
ki4070ma 47f51ab
updates
ki4070ma File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,6 +19,7 @@ | |
import os | ||
import sys | ||
import unittest | ||
from typing import Any, List, TypeVar | ||
|
||
from sauceclient import SauceClient | ||
|
||
|
@@ -29,8 +30,8 @@ | |
sauce = SauceClient(SAUCE_USERNAME, SAUCE_ACCESS_KEY) | ||
|
||
|
||
def on_platforms(platforms): | ||
def decorator(base_class): | ||
def on_platforms(platforms: List) -> Any: | ||
ki4070ma marked this conversation as resolved.
Show resolved
Hide resolved
|
||
def decorator(base_class: Any) -> None: | ||
ki4070ma marked this conversation as resolved.
Show resolved
Hide resolved
|
||
module = sys.modules[base_class.__module__].__dict__ | ||
for i, platform in enumerate(platforms): | ||
name = "%s_%s" % (base_class.__name__, i + 1) | ||
|
@@ -40,7 +41,7 @@ def decorator(base_class): | |
|
||
|
||
class SauceTestCase(unittest.TestCase): | ||
def setUp(self): | ||
def setUp(self) -> None: | ||
self.desired_capabilities['name'] = self.id() | ||
sauce_url = "http://%s:%[email protected]:80/wd/hub" | ||
self.driver = webdriver.Remote( | ||
|
@@ -49,7 +50,7 @@ def setUp(self): | |
) | ||
self.driver.implicitly_wait(30) | ||
|
||
def tearDown(self): | ||
def tearDown(self) -> None: | ||
print("Link to your job: https://saucelabs.com/jobs/%s" % self.driver.session_id) | ||
try: | ||
if sys.exc_info() == (None, None, None): | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👋