mirror of
https://github.com/blacktop/ipsw.git
synced 2026-06-07 12:27:36 +00:00
Refactor diff jobs into task-owned renderers with persistent cache support, root-confined walkers, and quieter Mach-O/Firmware output.
22 lines
678 B
Go
22 lines
678 B
Go
package diff
|
|
|
|
import "testing"
|
|
|
|
// TestTopLevelTasksAreCacheable documents that every top-level task implements
|
|
// CacheableTask so a fully-cached warm rerun runs ZERO top-level Parse work. A
|
|
// type assertion guards against an accidental future opt-out that would silently
|
|
// reintroduce uncached parse work on a warm rerun.
|
|
func TestTopLevelTasksAreCacheable(t *testing.T) {
|
|
for name, task := range map[string]Task{
|
|
"kexts": &kextsTask{},
|
|
"iboot": &ibootTask{},
|
|
"kdks": &kdksTask{},
|
|
"firmwares": &firmwaresTask{},
|
|
"sandbox": &sandboxTask{},
|
|
} {
|
|
if _, ok := task.(CacheableTask); !ok {
|
|
t.Errorf("%s must implement CacheableTask", name)
|
|
}
|
|
}
|
|
}
|