# Class com.ustadmobile.libcache.UstadCacheJvmTest

13 tests | 0 failures | 0 ignored | 1.157s duration
| 100% successful

- Tests
- Standard error

## Tests

Test | Method name | Duration | Result
--- | --- | --- | ---
givenCompressableFileStored_whenRequestMadeWithoutAcceptEncoding_thenWillBeRetrievedAsCacheHitAndBeCompressed[jvm] | givenCompressableFileStored_whenRequestMadeWithoutAcceptEncoding_thenWillBeRetrievedAsCacheHitAndBeCompressed | 0.047s | passed
givenCompressableFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndBeCompressed[jvm] | givenCompressableFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndBeCompressed | 0.048s | passed
givenEmptyFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHit[jvm] | givenEmptyFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHit | 0.054s | passed
givenEntryLocked_whenLockRemoved_thenWillBeMovedToCacheDir[jvm] | givenEntryLocked_whenLockRemoved_thenWillBeMovedToCacheDir | 0.086s | passed
givenEntryNotLocked_whenLockAdded_thenWillBeMovedToPersistentDir[jvm] | givenEntryNotLocked_whenLockAdded_thenWillBeMovedToPersistentDir | 0.065s | passed
givenEntryNotStored_whenRetrieved_thenWillReturnNull[jvm] | givenEntryNotStored_whenRetrieved_thenWillReturnNull | 0.058s | passed
givenFileCachedAndStored_whenPartialRequestMadeIfRangeNotMatched_thenWillReceiveFullResponse[jvm] | givenFileCachedAndStored_whenPartialRequestMadeIfRangeNotMatched_thenWillReceiveFullResponse | 0.058s | passed
givenFileCachedAndStored_whenPartialRequestMade_thenWillReceivePartialData[jvm] | givenFileCachedAndStored_whenPartialRequestMade_thenWillReceivePartialData | 0.072s | passed
givenFileCachedAndStored_whenRequestHasCacheValidationHeaders_thenShouldRespond304NotModified[jvm] | givenFileCachedAndStored_whenRequestHasCacheValidationHeaders_thenShouldRespond304NotModified | 0.410s | passed
givenLockedEntryStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndSavedInPersistentPath[jvm] | givenLockedEntryStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndSavedInPersistentPath | 0.055s | passed
givenNonCompressableFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndNotCompressed[jvm] | givenNonCompressableFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndNotCompressed | 0.073s | passed
givenResponseIsNotUpdated_whenStored_thenWillUpdateLastAccessAndValidationTime[jvm] | givenResponseIsNotUpdated_whenStored_thenWillUpdateLastAccessAndValidationTime | 0.058s | passed
givenResponseIsUpdated_whenRetrieved_thenLatestResponseWillBeReturned[jvm] | givenResponseIsUpdated_whenRetrieved_thenLatestResponseWillBeReturned | 0.073s | passed

## Standard error

    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit18397066561100419255/junit16199638869437531898/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/blank.txt to /tmp/junit11885013020812686764/junit5139230449104558011/tmpWork/1.tmp (integrity=sha256-47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=)
    May 20, 2026 10:58:47 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/blank.txt
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/blank.txt
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit10699444670939164157/junit10533376090193963985/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): add retention locks for http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): moveToNewPath (http://www.server.com/file.png) /tmp/junit10699444670939164157/junit10533376090193963985/cache/f4f46795-24bb-435e-ba6e-f12cef9cf3ff -> /tmp/junit10699444670939164157/junit10533376090193963985/persistent/f4f46795-24bb-435e-ba6e-f12cef9cf3ff
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit10110054008931047958/junit16798333070459683096/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): add retention locks for http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit4327374565585198606/junit4456322410140106896/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): remove retention locks for #1779303528242http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): moveToNewPath (http://www.server.com/file.png) /tmp/junit4327374565585198606/junit4456322410140106896/persistent/e98657d2-836f-40bc-9bc9-2d7bef9a6730 -> /tmp/junit4327374565585198606/junit4456322410140106896/cache/e98657d2-836f-40bc-9bc9-2d7bef9a6730
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/ustadmobile-epub.js to /tmp/junit10473893154228274060/junit6007092915343235374/tmpWork/1.tmp (integrity=sha256-VSq6jc4LzKolTOOJz3m0EyOgcFjLiWDjIhq5d2YB7fM=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/ustadmobile-epub.js
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/ustadmobile-epub.js
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/ustadmobile-epub.js to /tmp/junit9582399478939963506/junit14333671931469913367/tmpWork/1.tmp (integrity=sha256-VSq6jc4LzKolTOOJz3m0EyOgcFjLiWDjIhq5d2YB7fM=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/ustadmobile-epub.js
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/ustadmobile-epub.js
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit10785662491758550561/junit13370946893150083236/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): add retention locks for http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit8285607954107190354/junit7016466957403644724/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit14267740922118666957/junit2240443888857774500/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    May 20, 2026 10:58:48 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png