Cache processed images by their source path

Fixes #6269
This commit is contained in:
Bjørn Erik Pedersen
2019-09-03 10:36:09 +02:00
parent 018494f363
commit 8624b9fe9e
9 changed files with 127 additions and 33 deletions

View File

@@ -66,6 +66,8 @@ func newTestResourceSpec(desc specDescriptor) *Spec {
afs = afero.NewMemMapFs()
}
afs = hugofs.NewBaseFileDecorator(afs)
c := desc.c
cfg := createTestCfg()
@@ -118,7 +120,7 @@ func newTestResourceOsFs(c *qt.C) (*Spec, string) {
cfg.Set("workingDir", workDir)
fs := hugofs.NewFrom(hugofs.Os, cfg)
fs := hugofs.NewFrom(hugofs.NewBaseFileDecorator(hugofs.Os), cfg)
fs.Destination = &afero.MemMapFs{}
s, err := helpers.NewPathSpec(fs, cfg, nil)