Commit 1865f873 authored by Reinout van Rees's avatar Reinout van Rees

Added test. Faulty cached files should report their location

See #245
parent 3cbb51d7
......@@ -267,7 +267,7 @@ Clean up:
>>> rmdir('cache')
Offline mode and installation from cache
----------------------------~~~~~~~~~~~~
----------------------------------------
If we run buildout in offline mode now, it will fail because it cannot get at
the remote configuration file needed by the user's defaults:
......@@ -505,6 +505,30 @@ While:
Error: No-longer supported "extended-by" option found in http://localhost/base.cfg.
Reporting cached locations for downloads of faulty config files
---------------------------------------------------------------
A downloaded config file might be invalid. A cancelled buildout run, an
accidentally gzip-encoded download and so on.
>>> write(server_data, 'faulty.cfg', """\
... This is definitively not
... a proper() config file.
... """)
>>> write('buildout.cfg', """\
... [buildout]
... extends = %sfaulty.cfg
... """ % server_url)
>>> print_(system(buildout))
While:
Initializing.
...
MissingSectionHeaderError: File contains no section headers.
file: http://localhost/faulty.cfg (cached at ...), line: 1
'This is definitively not\n'
Clean up
--------
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment