jdk.nashorn.internal.ir.annotations.Ignore Java Examples

The following examples show how to use jdk.nashorn.internal.ir.annotations.Ignore. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ExpClaimAllowMissingExpValidationTest.java    From tomee with Apache License 2.0 6 votes vote down vote up
@Ignore
@RunAsClient
@Test(groups = TEST_GROUP_CONFIG,
    description = "Validate the the expiration timestamp is checked")
public void testExpiredToken() throws Exception {
    Reporter.log("testKeyAsPEM, expect HTTP_OK");

    PrivateKey privateKey = TokenUtils.readPrivateKey("/privateKey4k.pem");
    String kid = "/privateKey4k.pem";
    HashMap<String, Long> timeClaims = new HashMap<>();
    String token = TokenUtils.generateTokenString(privateKey, kid, "/Token1.json", Collections.singleton(TokenUtils.InvalidClaims.EXP), timeClaims);

    String uri = baseURL.toExternalForm() + "endp/verifyKeyLocationAsPEMResource";
    WebTarget echoEndpointTarget = ClientBuilder.newClient()
        .target(uri)
        ;

    Response response = echoEndpointTarget.request(APPLICATION_JSON).header(HttpHeaders.AUTHORIZATION, "Bearer "+token).get();
    Assert.assertEquals(response.getStatus(), HttpURLConnection.HTTP_UNAUTHORIZED);
}
 
Example #2
Source File: ExpClaimAllowMissingExpValidationTest.java    From tomee with Apache License 2.0 6 votes vote down vote up
@Ignore
@RunAsClient
@Test(groups = TEST_GROUP_CONFIG,
    description = "Validate the the expiration timestamp is checked")
public void testNoExpClaimToken() throws Exception {
    Reporter.log("testKeyAsPEM, expect HTTP_OK");

    PrivateKey privateKey = TokenUtils.readPrivateKey("/privateKey4k.pem");
    String kid = "/privateKey4k.pem";
    HashMap<String, Long> timeClaims = new HashMap<>();
    String token = TokenUtils.generateTokenString(privateKey, kid, "/Token1NoExp.json", Collections.singleton(TokenUtils.InvalidClaims.EXP), timeClaims);

    String uri = baseURL.toExternalForm() + "endp/verifyKeyLocationAsPEMResource";
    WebTarget echoEndpointTarget = ClientBuilder.newClient()
        .target(uri)
        ;

    Response response = echoEndpointTarget.request(APPLICATION_JSON).header(HttpHeaders.AUTHORIZATION, "Bearer "+token).get();
    Assert.assertEquals(response.getStatus(), HttpURLConnection.HTTP_OK);
    String replyString = response.readEntity(String.class);
    JsonReader jsonReader = Json.createReader(new StringReader(replyString));
    JsonObject reply = jsonReader.readObject();
    Reporter.log(reply.toString());
    Assert.assertTrue(reply.getBoolean("pass"), reply.getString("msg"));
}
 
Example #3
Source File: TestDirectByteBufferPool.java    From dble with GNU General Public License v2.0 5 votes vote down vote up
@Test @Ignore
public void testAllocateTime() {
    int pageSize = 1024 * 1024 * 10;
    int allocTimes = 20480;
    int size = 4096;
    DirectByteBufferPool pool = new DirectByteBufferPool(pageSize, (short) 256, (short) 8);
    ByteBuffer[] byteBuffer = new ByteBuffer[allocTimes];
    long start = System.currentTimeMillis();
    for (int i = 0; i < allocTimes; i++) {
        byteBuffer[i] = pool.allocate(size);
    }
    long used = (System.currentTimeMillis() - start);
    System.out.println("total used time  " + used + " avg speed " + allocTimes / used);
}
 
Example #4
Source File: ToApiFutureConverterTest.java    From future-converter with Apache License 2.0 4 votes vote down vote up
@Test
@Ignore
public void testCancelBeforeConversion() throws ExecutionException, InterruptedException {
    // completable futures can not be canceled
}
 
Example #5
Source File: ToListenableFutureConverterTest.java    From future-converter with Apache License 2.0 4 votes vote down vote up
@Test
@Ignore
public void testCancelBeforeConversion() throws ExecutionException, InterruptedException {
    // completable futures can not be canceled
}
 
Example #6
Source File: ToListenableFutureConverterTest.java    From future-converter with Apache License 2.0 4 votes vote down vote up
@Test
@Ignore
public void testCancelBeforeConversion() throws ExecutionException, InterruptedException {
    // completable futures can not be canceled
}