Test before cache file before trying to open it