summaryrefslogtreecommitdiffstats
path: root/hugolib/testhelpers_test.go
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2022-09-14 11:58:45 +0200
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2022-09-14 19:09:20 +0200
commit74daca6b3050d96cd3a08b13f45de24edb450163 (patch)
treed740f7e7174c4685dae8cb262a790300b005be76 /hugolib/testhelpers_test.go
parent1fd4c562afd467f246c632e9f3fed0a1f350d8dc (diff)
Support PostProcess for all file types
Not just HTML. Fixes #10269
Diffstat (limited to 'hugolib/testhelpers_test.go')
-rw-r--r--hugolib/testhelpers_test.go8
1 files changed, 6 insertions, 2 deletions
diff --git a/hugolib/testhelpers_test.go b/hugolib/testhelpers_test.go
index 46fa35deb..ca74e9340 100644
--- a/hugolib/testhelpers_test.go
+++ b/hugolib/testhelpers_test.go
@@ -764,8 +764,12 @@ func (s *sitesBuilder) AssertImage(width, height int, filename string) {
func (s *sitesBuilder) AssertNoDuplicateWrites() {
s.Helper()
- d := s.Fs.PublishDir.(hugofs.DuplicatesReporter)
- s.Assert(d.ReportDuplicates(), qt.Equals, "")
+ hugofs.WalkFilesystems(s.Fs.PublishDir, func(fs afero.Fs) bool {
+ if dfs, ok := fs.(hugofs.DuplicatesReporter); ok {
+ s.Assert(dfs.ReportDuplicates(), qt.Equals, "")
+ }
+ return false
+ })
}
func (s *sitesBuilder) FileContent(filename string) string {