caddy/caddyhttp
ericdreeves 08c17c7c31 Add Files action to template context. (closes #1198) (#1226)
* Add Files action to template context. (#1198)

* Fixes to testFiles().

- Set os.ModePerm on directories created during test.
- Use filepath.Join() to create directory path.
- Use Fatalf, not Fatal.

* Make additional fixes to test cases.

* Fix test cases to use correct path format.

Dir.Open() in net/http requires '/'-separated paths while
filepath.Join() may produce paths with different separator.

* Remove directory created by test at end of loop.

* Close the FileSystem before returning.

* Initialize names slice to the number of entries.

Also, do not call os.RemoveAll() unless the path to the directory
is a valid one.
2016-11-01 22:04:53 -06:00
..
2016-09-05 10:20:34 -06:00
2016-09-05 10:20:34 -06:00
2016-10-11 10:34:51 +08:00
2016-10-11 10:34:51 +08:00
2016-10-25 09:28:53 -06:00
2016-09-05 10:20:34 -06:00
2016-09-05 10:20:34 -06:00
2016-09-05 10:20:34 -06:00