# Class com.ustadmobile.libcache.UstadCacheJvmTest

13 tests | 0 failures | 0 ignored | 0.976s 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.047s | passed
givenEmptyFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHit[jvm] | givenEmptyFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHit | 0.048s | passed
givenEntryLocked_whenLockRemoved_thenWillBeMovedToCacheDir[jvm] | givenEntryLocked_whenLockRemoved_thenWillBeMovedToCacheDir | 0.056s | passed
givenEntryNotLocked_whenLockAdded_thenWillBeMovedToPersistentDir[jvm] | givenEntryNotLocked_whenLockAdded_thenWillBeMovedToPersistentDir | 0.068s | passed
givenEntryNotStored_whenRetrieved_thenWillReturnNull[jvm] | givenEntryNotStored_whenRetrieved_thenWillReturnNull | 0.048s | passed
givenFileCachedAndStored_whenPartialRequestMadeIfRangeNotMatched_thenWillReceiveFullResponse[jvm] | givenFileCachedAndStored_whenPartialRequestMadeIfRangeNotMatched_thenWillReceiveFullResponse | 0.050s | passed
givenFileCachedAndStored_whenPartialRequestMade_thenWillReceivePartialData[jvm] | givenFileCachedAndStored_whenPartialRequestMade_thenWillReceivePartialData | 0.055s | passed
givenFileCachedAndStored_whenRequestHasCacheValidationHeaders_thenShouldRespond304NotModified[jvm] | givenFileCachedAndStored_whenRequestHasCacheValidationHeaders_thenShouldRespond304NotModified | 0.342s | passed
givenLockedEntryStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndSavedInPersistentPath[jvm] | givenLockedEntryStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndSavedInPersistentPath | 0.047s | passed
givenNonCompressableFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndNotCompressed[jvm] | givenNonCompressableFileStored_whenRequestMade_thenWillBeRetrievedAsCacheHitAndNotCompressed | 0.053s | passed
givenResponseIsNotUpdated_whenStored_thenWillUpdateLastAccessAndValidationTime[jvm] | givenResponseIsNotUpdated_whenStored_thenWillUpdateLastAccessAndValidationTime | 0.059s | passed
givenResponseIsUpdated_whenRetrieved_thenLatestResponseWillBeReturned[jvm] | givenResponseIsUpdated_whenRetrieved_thenLatestResponseWillBeReturned | 0.056s | passed

## Standard error

    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit3645022558598889869/junit4508888473796860948/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/blank.txt to /tmp/junit1752330998845001633/junit5401778925129184897/tmpWork/1.tmp (integrity=sha256-47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/blank.txt
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/blank.txt
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit4585636994321536032/junit11080721826379588423/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): add retention locks for http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): moveToNewPath (http://www.server.com/file.png) /tmp/junit4585636994321536032/junit11080721826379588423/cache/9d6e7cad-76e0-4c7c-b610-46e05b5a467b -> /tmp/junit4585636994321536032/junit11080721826379588423/persistent/9d6e7cad-76e0-4c7c-b610-46e05b5a467b
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit2244700859407950877/junit3412804123489707222/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): add retention locks for http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit3610943096891996739/junit1664271087204736350/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): remove retention locks for #1775390812771http://www.server.com/file.png
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): moveToNewPath (http://www.server.com/file.png) /tmp/junit3610943096891996739/junit1664271087204736350/persistent/77d74751-114f-4046-8168-309525a7ecb9 -> /tmp/junit3610943096891996739/junit1664271087204736350/cache/77d74751-114f-4046-8168-309525a7ecb9
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/ustadmobile-epub.js to /tmp/junit10069941257423108619/junit14520720407987245004/tmpWork/1.tmp (integrity=sha256-VSq6jc4LzKolTOOJz3m0EyOgcFjLiWDjIhq5d2YB7fM=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/ustadmobile-epub.js
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/ustadmobile-epub.js
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/ustadmobile-epub.js to /tmp/junit5658811293409067755/junit2834441847400150661/tmpWork/1.tmp (integrity=sha256-VSq6jc4LzKolTOOJz3m0EyOgcFjLiWDjIhq5d2YB7fM=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/ustadmobile-epub.js
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/ustadmobile-epub.js
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit7046145118536198541/junit10498524729405681575/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:52 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): add retention locks for http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit7212878958059797205/junit11946591327895410265/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): storerequest 1 entries
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): copied request data for http://www.server.com/file.png to /tmp/junit13337269959266411500/junit2092091640822404799/tmpWork/1.tmp (integrity=sha256-hlfF4oGFRfane2XiRyLv02LtOJ4Va2UanpQV0im/K8I=)
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINEST: [VERBOSE] UstadCache - UstadCache(): cacheEntries created 1 entries
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): deleting 0 tmp files
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): db transaction completed
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    INFO: [INFO] UstadCache - UstadCache(): Retrieve http://www.server.com/file.png
    Apr 05, 2026 4:06:53 PM io.github.aakira.napier.DebugAntilog performLog
    FINE: [DEBUG] UstadCache - UstadCache(): FOUND http://www.server.com/file.png