Class AuthorizationTokenRefreshTest

java.lang.Object
org.kohsuke.github.AbstractGitHubWireMockTest
org.kohsuke.github.extras.authorization.AuthorizationTokenRefreshTest

public class AuthorizationTokenRefreshTest extends AbstractGitHubWireMockTest
Test authorization token refresh.
  • Constructor Details

    • AuthorizationTokenRefreshTest

      public AuthorizationTokenRefreshTest()
      Instantiates a new test.
  • Method Details

    • getWireMockOptions

      protected com.github.tomakehurst.wiremock.core.WireMockConfiguration getWireMockOptions()
      Gets the wire mock options.
      Overrides:
      getWireMockOptions in class AbstractGitHubWireMockTest
      Returns:
      the wire mock options
    • testNewWhenOldOneExpires

      public void testNewWhenOldOneExpires() throws IOException
      Retried request should get new token when the old one expires.
      Throws:
      IOException - the exception
    • testNotNewWhenOldOneIsStillValid

      public void testNotNewWhenOldOneIsStillValid() throws IOException
      Retried request should not get new token when the old one is still valid.
      Throws:
      IOException - the exception