Skip to content

java.time.Duration not present before SDK 26 #1843

@isuPatches

Description

@isuPatches

Unable to use Mockito 3.1.7+ with Android on lower SDK devices.

Reason:

https://developer.android.com/reference/java/time/Duration <-- This was not added to Android until SDK 26.

https://developer.android.com/about/dashboards <-- here are some distribution stats. Most noticeably, this would impact testing for 70% of the market and is not ideal.

java.lang.NoClassDefFoundError: java.time.Duration
at org.mockito.Mockito.timeout(Mockito.java:2856)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions