tests:
    -
        description: "Valid read preference options are parsed correctly"
        uri: "mongodb://example.com/?readPreference=primaryPreferred&readPreferenceTags=dc:ny,rack:1&maxStalenessSeconds=120&readPreferenceTags=dc:ny"
        valid: true
        warning: false
        hosts: ~
        auth: ~
        options:
            readPreference: "primaryPreferred"
            readPreferenceTags:
                -
                    dc: "ny"
                    rack: "1"
                -
                    dc: "ny"
            maxStalenessSeconds: 120
    -
        description: "Single readPreferenceTags is parsed as array of size one"
        uri: "mongodb://example.com/?readPreference=secondary&readPreferenceTags=dc:ny"
        valid: true
        warning: false
        hosts: ~
        auth: ~
        options:
            readPreferenceTags:
                -
                    dc: "ny"
    -
        description: "Invalid readPreferenceTags causes a warning"
        uri: "mongodb://example.com/?readPreferenceTags=invalid"
        valid: true
        warning: true
        hosts: ~
        auth: ~
        options: {}
    -
        description: "Non-numeric maxStalenessSeconds causes a warning"
        uri: "mongodb://example.com/?maxStalenessSeconds=invalid"
        valid: true
        warning: true
        hosts: ~
        auth: ~
        options: {}
    -
        description: "Too low maxStalenessSeconds causes a warning"
        uri: "mongodb://example.com/?maxStalenessSeconds=-2"
        valid: true
        warning: true
        hosts: ~
        auth: ~
        options: {}