-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enable some ruff rules on tests/ folder (#4212)
- Loading branch information
1 parent
3276393
commit 2597fc3
Showing
22 changed files
with
55 additions
and
57 deletions.
There are no files selected for viewing
This file contains 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 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 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 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 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 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 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 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 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 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 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 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 |
---|---|---|
|
@@ -103,7 +103,7 @@ def test_db_user(self, excluded_operations=()): | |
"""Username for accessing the database.""" | ||
db_container = context.scenario.get_container_by_dd_integration_name(self.db_service) | ||
|
||
for db_operation, span in self.get_spans(excluded_operations=excluded_operations): | ||
for _, span in self.get_spans(excluded_operations=excluded_operations): | ||
assert span["meta"]["db.user"].casefold() == db_container.db_user.casefold() | ||
|
||
@missing_feature(library="python", reason="not implemented yet") | ||
|
@@ -112,7 +112,7 @@ def test_db_instance(self, excluded_operations=()): | |
"""The name of the database being connected to. Database instance name. Formerly db.name""" | ||
db_container = context.scenario.get_container_by_dd_integration_name(self.db_service) | ||
|
||
for db_operation, span in self.get_spans(excluded_operations=excluded_operations): | ||
for _, span in self.get_spans(excluded_operations=excluded_operations): | ||
assert span["meta"]["db.instance"] == db_container.db_instance | ||
|
||
@missing_feature(library="python", reason="not implemented yet") | ||
|
@@ -187,7 +187,7 @@ def test_db_jdbc_drive_classname(self): | |
assert span["meta"]["db.jdbc.driver_classname"].strip(), f"Test is failing for {db_operation}" | ||
|
||
def test_error_message(self): | ||
for db_operation, span in self.get_spans(operations=["select_error"]): | ||
for _, span in self.get_spans(operations=["select_error"]): | ||
# A string representing the error message. | ||
assert span["meta"]["error.message"].strip() | ||
|
||
|
@@ -257,7 +257,7 @@ def test_db_name(self): | |
super().test_db_name() | ||
|
||
@bug(context.library < "[email protected]", reason="APMRP-360") | ||
def test_db_user(self, excluded_operations=()): | ||
def test_db_user(self): | ||
super().test_db_user() | ||
|
||
|
||
|
This file contains 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 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 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 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 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 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 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.