You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2018/08/14 22:35:22 UTC

[GitHub] r39132 commented on a change in pull request #3730: [AIRFLOW-2882] Add import and export for pool cli using JSON

r39132 commented on a change in pull request #3730: [AIRFLOW-2882] Add import and export for pool cli using JSON
URL: https://github.com/apache/incubator-airflow/pull/3730#discussion_r210125544
 
 

 ##########
 File path: tests/cli/test_cli.py
 ##########
 @@ -165,3 +166,38 @@ def test_local_run(self):
             ti.refresh_from_db()
             state = ti.current_state()
             self.assertEqual(state, State.SUCCESS)
+
+    def test_cli_pool_import_export(self):
+        pool_config_input = {
+            "s3_pool": {
+                "description": "This is my test s3_pool",
+                "slots": 5
+            },
+            "s3_pool2": {
+                "description": "This is my test s3_pool",
+                "slots": 8
+            }
+        }
+        with open('pool_import.json', mode='w', encoding='utf-8') as f:
+            json.dump(pool_config_input, f)
+        process_import = psutil.Popen(["airflow", "pool", "-i", "pool_import.json"])
+        sleep(3)  # wait for webserver to start
 
 Review comment:
   @Fokko This looks good to me.. .do you want to take a quick look? The test failures are unrelated to the code changes.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services