[ 
https://issues.apache.org/jira/browse/BEAM-9093?focusedWorklogId=376466&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-376466
 ]

ASF GitHub Bot logged work on BEAM-9093:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 23/Jan/20 19:34
            Start Date: 23/Jan/20 19:34
    Worklog Time Spent: 10m 
      Work Description: angoenka commented on pull request #10613: [BEAM-9093] 
Log invalid overwrites in pipeline options
URL: https://github.com/apache/beam/pull/10613#discussion_r370313458
 
 

 ##########
 File path: sdks/python/apache_beam/options/pipeline_options_test.py
 ##########
 @@ -264,6 +264,18 @@ def test_override_options(self):
     self.assertEqual(options.get_all_options()['num_workers'], 5)
     self.assertTrue(options.get_all_options()['mock_flag'])
 
+  def test_override_init_options(self):
+    base_flags = ['--num_workers', '5']
+    options = PipelineOptions(base_flags, mock_flag=True)
+    self.assertEqual(options.get_all_options()['num_workers'], 5)
+    self.assertEqual(options.get_all_options()['mock_flag'], True)
+
+  def test_invalid_override_init_options(self):
+    base_flags = ['--num_workers', '5']
+    options = PipelineOptions(base_flags, mock_invalid_flag=True)
+    self.assertEqual(options.get_all_options()['num_workers'], 5)
+    self.assertEqual(options.get_all_options()['mock_flag'], False)
 
 Review comment:
   Checking log message for test correctness will not be idle i suppose.
 
----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 376466)
    Time Spent: 1h 10m  (was: 1h)

> Pipeline options which with different underlying store variable does not get 
> over written
> -----------------------------------------------------------------------------------------
>
>                 Key: BEAM-9093
>                 URL: https://issues.apache.org/jira/browse/BEAM-9093
>             Project: Beam
>          Issue Type: Bug
>          Components: sdk-py-core
>            Reporter: Ankur Goenka
>            Priority: Major
>          Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Example:
> PipelineOptions(flags=[],**\{'no_use_public_ips': True,})
> Expectation: use_public_ips should be set False.
> Actual: the value is not used as its not passed through argparser
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to