Annotation Type WithCredentials


  • @Retention(RUNTIME)
    @Target({METHOD,TYPE})
    @Inherited
    @Documented
    @RuleAnnotation(value=RuleImpl.class,
                    priority=11)
    public @interface WithCredentials
    Indicates that a test requires credentials. Adds required credentials in the credential plugin

    Supports:

    -Username/password:

    Example: @WithCredentials(credentialType = WithCredentials.USERNAME_PASSWORD, values = {"username", "password"})

    -Username/sshKey:

    Example: @WithCredentials(credentialType = WithCredentials.SSH_USERNAME_PRIVATE_KEY, values = {"username", "/ssh_keys/unsafe"})

    Author:
    Karl Matthias
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      String id
      Optional ID to specify.
    • Field Detail

      • USERNAME_PASSWORD

        static final int USERNAME_PASSWORD
      • SSH_USERNAME_PRIVATE_KEY

        static final int SSH_USERNAME_PRIVATE_KEY
    • Element Detail

      • credentialType

        int credentialType
      • id

        String id
        Optional ID to specify.
        Default:
        ""