Changeset 83906 in webkit


Ignore:
Timestamp:
Apr 14, 2011 3:55:46 PM (13 years ago)
Author:
eric@webkit.org
Message:

2011-04-14 Eric Seidel <eric@webkit.org>

Reviewed by Adam Barth.

commit-queue fails to catch IOError when results.html is missing
https://bugs.webkit.org/show_bug.cgi?id=58589

  • Scripts/webkitpy/tool/commands/queues.py:
  • Scripts/webkitpy/tool/commands/queues_unittest.py:
Location:
trunk/Tools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r83903 r83906  
     12011-04-14  Eric Seidel  <eric@webkit.org>
     2
     3        Reviewed by Adam Barth.
     4
     5        commit-queue fails to catch IOError when results.html is missing
     6        https://bugs.webkit.org/show_bug.cgi?id=58589
     7
     8        * Scripts/webkitpy/tool/commands/queues.py:
     9        * Scripts/webkitpy/tool/commands/queues_unittest.py:
     10
    1112011-04-14  Kevin Ollivier  <kevino@theolliviers.com>
    212
  • trunk/Tools/Scripts/webkitpy/tool/commands/queues.py

    r83876 r83906  
    317317        try:
    318318            return self._tool.filesystem.read_text_file(path)
    319         except OSError, e:  # File does not exist or can't be read.
     319        except IOError, e:  # File does not exist or can't be read.
    320320            return None
    321321
  • trunk/Tools/Scripts/webkitpy/tool/commands/queues_unittest.py

    r83876 r83906  
    379379        OutputCapture().assert_outputs(self, queue.report_flaky_tests, [QueuesTest.mock_work_item, test_results, MockZipFile()], expected_stderr=expected_stderr)
    380380
     381    def test_missing_layout_test_results(self):
     382        queue = CommitQueue()
     383        tool = MockTool()
     384        results_path = '/mock/results.html'
     385        tool.filesystem = MockFileSystem({results_path: None})
     386        queue.bind_to_tool(tool)
     387        # Make sure that our filesystem mock functions as we expect.
     388        self.assertRaises(IOError, tool.filesystem.read_text_file, results_path)
     389        # layout_test_results shouldn't raise even if the results.html file is missing.
     390        self.assertEquals(queue.layout_test_results(), None)
     391
    381392    def test_layout_test_results(self):
    382393        queue = CommitQueue()
Note: See TracChangeset for help on using the changeset viewer.