mirror of
https://github.com/gohugoio/hugo.git
synced 2025-04-27 14:10:31 +03:00
parent
1fd4c562af
commit
74daca6b30
9 changed files with 265 additions and 24 deletions
|
@ -71,8 +71,12 @@ func TestTransform(t *testing.T) {
|
|||
// Verify that we publish the same file once only.
|
||||
assertNoDuplicateWrites := func(c *qt.C, spec *Spec) {
|
||||
c.Helper()
|
||||
d := spec.Fs.PublishDir.(hugofs.DuplicatesReporter)
|
||||
c.Assert(d.ReportDuplicates(), qt.Equals, "")
|
||||
hugofs.WalkFilesystems(spec.Fs.PublishDir, func(fs afero.Fs) bool {
|
||||
if dfs, ok := fs.(hugofs.DuplicatesReporter); ok {
|
||||
c.Assert(dfs.ReportDuplicates(), qt.Equals, "")
|
||||
}
|
||||
return false
|
||||
})
|
||||
}
|
||||
|
||||
assertShouldExist := func(c *qt.C, spec *Spec, filename string, should bool) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue