Java Code Examples for com.oracle.java.testlibrary.Asserts#assertGTE()

The following examples show how to use com.oracle.java.testlibrary.Asserts#assertGTE() . 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: TestCapacityUntilGCWrapAround.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (Platform.is32bit()) {
        WhiteBox wb = WhiteBox.getWhiteBox();

        long before = wb.metaspaceCapacityUntilGC();
        // Now force possible overflow of capacity_until_GC.
        long after = wb.incMetaspaceCapacityUntilGC(MAX_UINT);

        Asserts.assertGTE(after, before,
                          "Increasing with MAX_UINT should not cause wrap around: " + after + " < " + before);
        Asserts.assertLTE(after, MAX_UINT,
                          "Increasing with MAX_UINT should not cause value larger than MAX_UINT:" + after);
    }
}
 
Example 2
Source File: CorrectnessTest.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (!Platform.isServer()) {
        System.out.println("ALL TESTS SKIPPED");
    }
    Asserts.assertGTE(args.length, 1);
    ProfilingType profilingType = ProfilingType.valueOf(args[0]);
    if (runTests(profilingType)) {
        System.out.println("ALL TESTS PASSED");
    } else {
        throw new RuntimeException("SOME TESTS FAILED");
    }
}
 
Example 3
Source File: TestCapacityUntilGCWrapAround.java    From jdk8u60 with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (Platform.is32bit()) {
        WhiteBox wb = WhiteBox.getWhiteBox();

        long before = wb.metaspaceCapacityUntilGC();
        // Now force possible overflow of capacity_until_GC.
        long after = wb.incMetaspaceCapacityUntilGC(MAX_UINT);

        Asserts.assertGTE(after, before,
                          "Increasing with MAX_UINT should not cause wrap around: " + after + " < " + before);
        Asserts.assertLTE(after, MAX_UINT,
                          "Increasing with MAX_UINT should not cause value larger than MAX_UINT:" + after);
    }
}
 
Example 4
Source File: CorrectnessTest.java    From jdk8u60 with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (!Platform.isServer()) {
        System.out.println("ALL TESTS SKIPPED");
    }
    Asserts.assertGTE(args.length, 1);
    ProfilingType profilingType = ProfilingType.valueOf(args[0]);
    if (runTests(profilingType)) {
        System.out.println("ALL TESTS PASSED");
    } else {
        throw new RuntimeException("SOME TESTS FAILED");
    }
}
 
Example 5
Source File: TestCapacityUntilGCWrapAround.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (Platform.is32bit()) {
        WhiteBox wb = WhiteBox.getWhiteBox();

        long before = wb.metaspaceCapacityUntilGC();
        // Now force possible overflow of capacity_until_GC.
        long after = wb.incMetaspaceCapacityUntilGC(MAX_UINT);

        Asserts.assertGTE(after, before,
                          "Increasing with MAX_UINT should not cause wrap around: " + after + " < " + before);
        Asserts.assertLTE(after, MAX_UINT,
                          "Increasing with MAX_UINT should not cause value larger than MAX_UINT:" + after);
    }
}
 
Example 6
Source File: CorrectnessTest.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (!Platform.isServer()) {
        System.out.println("ALL TESTS SKIPPED");
    }
    Asserts.assertGTE(args.length, 1);
    ProfilingType profilingType = ProfilingType.valueOf(args[0]);
    if (runTests(profilingType)) {
        System.out.println("ALL TESTS PASSED");
    } else {
        throw new RuntimeException("SOME TESTS FAILED");
    }
}
 
Example 7
Source File: TestCapacityUntilGCWrapAround.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (Platform.is32bit()) {
        WhiteBox wb = WhiteBox.getWhiteBox();

        long before = wb.metaspaceCapacityUntilGC();
        // Now force possible overflow of capacity_until_GC.
        long after = wb.incMetaspaceCapacityUntilGC(MAX_UINT);

        Asserts.assertGTE(after, before,
                          "Increasing with MAX_UINT should not cause wrap around: " + after + " < " + before);
        Asserts.assertLTE(after, MAX_UINT,
                          "Increasing with MAX_UINT should not cause value larger than MAX_UINT:" + after);
    }
}
 
Example 8
Source File: CorrectnessTest.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (!Platform.isServer()) {
        System.out.println("ALL TESTS SKIPPED");
    }
    Asserts.assertGTE(args.length, 1);
    ProfilingType profilingType = ProfilingType.valueOf(args[0]);
    if (runTests(profilingType)) {
        System.out.println("ALL TESTS PASSED");
    } else {
        throw new RuntimeException("SOME TESTS FAILED");
    }
}
 
Example 9
Source File: TestCapacityUntilGCWrapAround.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (Platform.is32bit()) {
        WhiteBox wb = WhiteBox.getWhiteBox();

        long before = wb.metaspaceCapacityUntilGC();
        // Now force possible overflow of capacity_until_GC.
        long after = wb.incMetaspaceCapacityUntilGC(MAX_UINT);

        Asserts.assertGTE(after, before,
                          "Increasing with MAX_UINT should not cause wrap around: " + after + " < " + before);
        Asserts.assertLTE(after, MAX_UINT,
                          "Increasing with MAX_UINT should not cause value larger than MAX_UINT:" + after);
    }
}
 
Example 10
Source File: CorrectnessTest.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
public static void main(String[] args) {
    if (!Platform.isServer()) {
        System.out.println("ALL TESTS SKIPPED");
    }
    Asserts.assertGTE(args.length, 1);
    ProfilingType profilingType = ProfilingType.valueOf(args[0]);
    if (runTests(profilingType)) {
        System.out.println("ALL TESTS PASSED");
    } else {
        throw new RuntimeException("SOME TESTS FAILED");
    }
}