container->add(State::class, new FileState($this->tempDir())); } /** * Resolve Pest's `.temp/` directory relative to this file so TIA's * caches share the same location as the rest of Pest's transient * state (PHPUnit result cache, coverage PHP dumps, etc.). */ private function tempDir(): string { return __DIR__ .DIRECTORY_SEPARATOR.'..' .DIRECTORY_SEPARATOR.'..' .DIRECTORY_SEPARATOR.'..' .DIRECTORY_SEPARATOR.'.temp'; } }