Skip to content

Commit af6be0a

Browse files
committed
test formatting fixed
1 parent 25c7cd7 commit af6be0a

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

tests/test_sheet_ql.py

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,11 @@ def setUp(self):
2020

2121
self.csv_path = os.path.join(self.test_dir, "sample.csv")
2222
pd.DataFrame(
23-
{"ID": [1, 2, 3], "Name": ["Alice", "Bob", "Charlie"], "Value": [100, 200, 150]}
23+
{
24+
"ID": [1, 2, 3],
25+
"Name": ["Alice", "Bob", "Charlie"],
26+
"Value": [100, 200, 150],
27+
}
2428
).to_csv(self.csv_path, index=False)
2529

2630
self.excel_path = os.path.join(self.test_dir, "sample.xlsx")
@@ -127,9 +131,9 @@ def test_06_yaml_script_interactive_run(self, mock_input):
127131
def test_07_load_command(self):
128132
"""Test loading a new file mid-session with the '.load' command."""
129133
self.tool._register_dataframes(self.tool._load_data([self.csv_path]))
130-
initial_tables = self.tool.db_connection.execute("SHOW TABLES;").fetchdf()[
131-
"name"
132-
].tolist()
134+
initial_tables = (
135+
self.tool.db_connection.execute("SHOW TABLES;").fetchdf()["name"].tolist()
136+
)
133137
self.assertIn("sample_csv", initial_tables)
134138
self.assertNotIn("sample_json", initial_tables)
135139

@@ -138,9 +142,9 @@ def test_07_load_command(self):
138142
):
139143
self.tool._add_new_files()
140144

141-
final_tables = self.tool.db_connection.execute("SHOW TABLES;").fetchdf()[
142-
"name"
143-
].tolist()
145+
final_tables = (
146+
self.tool.db_connection.execute("SHOW TABLES;").fetchdf()["name"].tolist()
147+
)
144148
self.assertIn("sample_csv", final_tables)
145149
self.assertIn("sample_json", final_tables)
146150

@@ -168,7 +172,7 @@ def test_09_exit_command_with_save_prompt(self, mock_export):
168172
"""Test that '.exit' prompts to save when results are staged."""
169173
self.tool.console.input.return_value = "y"
170174
self.tool.results_to_save["my_results"] = pd.DataFrame({"a": [1]})
171-
175+
172176
should_exit = self.tool._handle_meta_command(".exit")
173177

174178
self.assertTrue(should_exit)

0 commit comments

Comments
 (0)