summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVictor Chang <vichang@google.com>2023-08-30 11:43:26 +0100
committerVictor Chang <vichang@google.com>2023-08-30 12:05:15 +0100
commita6122ecb996527a67c99b474f417892b1d31a2d4 (patch)
tree77b808d6d27f55d511f5c79361b7ef92dde3ea6c
parentf9f6764d13c1306b4445b50a53e6b257f8f706d4 (diff)
downloadbouncycastle-a6122ecb996527a67c99b474f417892b1d31a2d4.tar.gz
Mark long-running BouncyCastle tests as @LargeTest
Bug: 297099034 Test: atest bouncycastle-host-tests Test: atest CtsLibcoreTestCases:com.android.org.bouncycastle -- --module-arg CtsLibcoreTestCases:exclude-annotation:android.platform.test.annotations.LargeTest Change-Id: Ia237840ec7c57b055aa26882c1938e0163498ad9
-rw-r--r--Android.bp1
-rw-r--r--bcprov/src/test/java/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java4
-rw-r--r--bcprov/src/test/java/org/bouncycastle/math/ec/test/ECPointTest.java3
-rw-r--r--repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java4
-rw-r--r--repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECPointTest.java3
5 files changed, 15 insertions, 0 deletions
diff --git a/Android.bp b/Android.bp
index 9abc0460..a1773cef 100644
--- a/Android.bp
+++ b/Android.bp
@@ -265,6 +265,7 @@ java_test_host {
static_libs: [
"bouncycastle-unbundled",
"junit",
+ "platform-test-annotations",
],
test_suites: ["general-tests"],
}
diff --git a/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java b/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java
index 20b8d323..27e89f00 100644
--- a/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java
+++ b/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java
@@ -19,6 +19,8 @@ import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
+import android.platform.test.annotations.LargeTest;
+
public class ECAlgorithmsTest extends TestCase
{
private static final int SCALE = 4;
@@ -32,6 +34,7 @@ public class ECAlgorithmsTest extends TestCase
}
// TODO Ideally, mark this test not to run by default
+ @LargeTest
public void testSumOfMultipliesComplete()
{
ArrayList x9s = getTestCurves();
@@ -51,6 +54,7 @@ public class ECAlgorithmsTest extends TestCase
}
// TODO Ideally, mark this test not to run by default
+ @LargeTest
public void testSumOfTwoMultipliesComplete()
{
ArrayList x9s = getTestCurves();
diff --git a/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECPointTest.java b/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECPointTest.java
index f53c9828..aaf2f5b6 100644
--- a/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECPointTest.java
+++ b/bcprov/src/test/java/org/bouncycastle/math/ec/test/ECPointTest.java
@@ -28,6 +28,8 @@ import org.bouncycastle.util.BigIntegers;
import org.bouncycastle.util.Integers;
import org.bouncycastle.util.encoders.Hex;
+import android.platform.test.annotations.LargeTest;
+
/**
* Test class for {@link org.bouncycastle.math.ec.ECPoint ECPoint}. All
* literature values are taken from "Guide to elliptic curve cryptography",
@@ -551,6 +553,7 @@ public class ECPointTest extends TestCase
* <code>implTestMultiply</code> and <code>implTestEncoding</code> for
* the standard elliptic curves as given in <code>SECNamedCurves</code>.
*/
+ @LargeTest
public void testAddSubtractMultiplyTwiceEncoding()
{
Set names = new HashSet(enumToList(ECNamedCurveTable.getNames()));
diff --git a/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java b/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java
index cf10fe45..ba944d77 100644
--- a/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java
+++ b/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECAlgorithmsTest.java
@@ -20,6 +20,8 @@ import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
+import android.platform.test.annotations.LargeTest;
+
/**
* @hide This class is not part of the Android public SDK API
*/
@@ -36,6 +38,7 @@ public class ECAlgorithmsTest extends TestCase
}
// TODO Ideally, mark this test not to run by default
+ @LargeTest
public void testSumOfMultipliesComplete()
{
ArrayList x9s = getTestCurves();
@@ -55,6 +58,7 @@ public class ECAlgorithmsTest extends TestCase
}
// TODO Ideally, mark this test not to run by default
+ @LargeTest
public void testSumOfTwoMultipliesComplete()
{
ArrayList x9s = getTestCurves();
diff --git a/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECPointTest.java b/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECPointTest.java
index 02dcebf2..0978d2ef 100644
--- a/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECPointTest.java
+++ b/repackaged/bcprov/src/test/java/com/android/org/bouncycastle/math/ec/test/ECPointTest.java
@@ -29,6 +29,8 @@ import com.android.org.bouncycastle.util.BigIntegers;
import com.android.org.bouncycastle.util.Integers;
import com.android.org.bouncycastle.util.encoders.Hex;
+import android.platform.test.annotations.LargeTest;
+
/**
* Test class for {@link com.android.org.bouncycastle.math.ec.ECPoint ECPoint}. All
* literature values are taken from "Guide to elliptic curve cryptography",
@@ -555,6 +557,7 @@ public class ECPointTest extends TestCase
* <code>implTestMultiply</code> and <code>implTestEncoding</code> for
* the standard elliptic curves as given in <code>SECNamedCurves</code>.
*/
+ @LargeTest
public void testAddSubtractMultiplyTwiceEncoding()
{
Set names = new HashSet(enumToList(ECNamedCurveTable.getNames()));