Github user JoshRosen commented on a diff in the pull request:

    https://github.com/apache/spark/pull/6714#discussion_r32702098
  
    --- Diff: python/pyspark/tests.py ---
    @@ -179,9 +179,12 @@ def test_in_memory_sort(self):
                              list(sorter.sorted(l, key=lambda x: -x, 
reverse=True)))
     
         def test_external_sort(self):
    +        class CustomizedSorter(ExternalSorter):
    +            def _next_limit(self):
    --- End diff --
    
    I think that we should add a comment here to explain why we're mocking out 
this part of the code; it doesn't seem self-evident to me and I'm worried that 
it's going to confuse future readers of this code.
    
    Also, do you think that it's worth adding a separate test case for this 
path and keeping the old test?  There might be some duplication of the code 
which does assertions over metrics, but we possibly can factor it out into a 
shared method.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to