Edgewall Software

Opened 14 years ago

Closed 14 years ago

#357 closed defect (fixed)

buggy test_with_statement on Windows

Reported by: cboos Owned by: cmlenz
Priority: major Milestone: 0.6
Component: Expression evaluation Version: 0.5.1
Keywords: Cc:

Description

r1090 won't work on Windows, as it uses a NamedTemporaryFile.

The doc says:

Whether the name can be used to open the file a second time, while the named temporary file is still open, varies across platforms (it can be so used on Unix; it cannot on Windows NT or later).

So the with open() ... statement will fail.

Better use mkstemp, I think.

Attachments (1)

fix-test_with_statement-r1090.patch (1.2 KB) - added by cboos 14 years ago.
Fix the failing test by using tempfile.mkstemp

Download all attachments as: .zip

Change History (2)

Changed 14 years ago by cboos

Fix the failing test by using tempfile.mkstemp

comment:1 Changed 14 years ago by cmlenz

  • Resolution set to fixed
  • Status changed from new to closed

Patch applied in r1091.

Note: See TracTickets for help on using tickets.