call site 2 for path.local.open
doc/test_conftest.py - line 69
64
65
66
67
68
69
70
71
72
73
74
75
76
77
   def test_doctest_eol(): 
       # XXX get rid of the next line: 
       py.magic.autopath().dirpath('conftest.py').copy(tmpdir.join('conftest.py'))
   
       ytxt = tmpdir.join('y.txt')
->     ytxt.write(py.code.Source(".. >>> 1 + 1\r\n   2\r\n\r\n"))
       config = py.test.config._reparse([ytxt]) 
       session = config.initsession()
       session.main()
       l = session.getitemoutcomepairs(Failed)
       assert len(l) == 0 
       l = session.getitemoutcomepairs(Passed)
       l2 = session.getitemoutcomepairs(Skipped)
       assert len(l+l2) == 2
path/local/local.py - line 276
273
274
275
276
277
278
279
280
   def write(self, content, mode='wb'):
       """ write string content into path. """
       s = str(content)
->     f = self.open(mode)
       try:
           f.write(s)
       finally:
           f.close()