• 
      

    Add test: Expect 404 on invalid review access.

    Review Request #3761 — Created Jan. 18, 2013 and submitted

    Information

    nh2
    Review Board
    master

    Reviewers

    Add test: Expect 404 on invalid review access.
    
    In particular, test if accessing the screenshots of a nonexistent review id fails.
    Fixes #2551.
    Test passes with http://reviews.reviewboard.org/r/3767 applied.
    Description From Last Updated

    Lots of resources can throw these exceptions. I think it's okay not to add this comment, as now, that's just …

    chipx86chipx86

    Can you make sure to follow the other unit test docstring structures for this? Should be like: """Testing the GET …

    chipx86chipx86

    Col: 80 E501 line too long (101 > 79 characters)

    reviewbotreviewbot
    NH
    reviewbot
    1. This is a review from Review Bot.
        Tool: PEP8 Style Checker
        Processed Files:
          reviewboard/webapi/tests.py
          reviewboard/webapi/resources.py
        Ignored Files:
      
      
    2. 
        
    chipx86
    1. 
        
    2. reviewboard/webapi/resources.py (Diff revision 1)
       
       
      Show all issues
      Lots of resources can throw these exceptions. I think it's okay not to add this comment, as now, that's just part of the API as documented.
    3. reviewboard/webapi/tests.py (Diff revision 1)
       
       
      Show all issues
      Can you make sure to follow the other unit test docstring structures for this? Should be like:
      
      """Testing the GET review-requests/<id>/screenshots/ API with an invalid review request ID"""
      
      Also, this needs to be one line. (Unit test docstrings are the one place that's okay to have over 80 chars in length)
    4. 
        
    NH
    reviewbot
    1. This is a review from Review Bot.
        Tool: PEP8 Style Checker
        Processed Files:
          reviewboard/webapi/tests.py
        Ignored Files:
      
      
    2. reviewboard/webapi/tests.py (Diff revision 2)
       
       
      Show all issues
      Col: 80
       E501 line too long (101 > 79 characters)
      
    3. 
        
    SM
    1. Ship It!
    2. 
        
    NH
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-1.7.x (980c853). Thanks!