jedcunningham commented on code in PR #32810:
URL: https://github.com/apache/airflow/pull/32810#discussion_r1279580534


##########
tests/cli/commands/test_db_command.py:
##########
@@ -37,8 +37,11 @@ def setup_class(cls):
 
     @mock.patch("airflow.cli.commands.db_command.db.initdb")
     def test_cli_initdb(self, mock_initdb):
-        db_command.initdb(self.parser.parse_args(["db", "init"]))
-
+        with pytest.warns(
+            expected_warning=DeprecationWarning, match="ActionCommand `init` 
is deprecated"
+        ) as warning_record:

Review Comment:
   ```suggestion
           with pytest.warns(DeprecationWarning, match="`init` is deprecated"):
   ```
   
   Normally the expected warning is a positional arg. That coupled with the 
warning message changes above might allow this to land on 1 line?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to