Skip to content

Commit

Permalink
k256: re-enable cross tests (#248)
Browse files Browse the repository at this point in the history
  • Loading branch information
tarcieri authored Dec 6, 2020
1 parent 000dbeb commit c146760
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 32 deletions.
58 changes: 28 additions & 30 deletions .github/workflows/k256.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,33 +102,31 @@ jobs:
- run: cargo test --release --target ${{ matrix.target }} --features field-montgomery
- run: cargo test --release --target ${{ matrix.target }} --all-features

# Cross-compiled tests
# TODO(tarcieri): re-enable these after deps are no longer git-sourced
# cross:
# strategy:
# matrix:
# include:
# # ARM64
# - target: aarch64-unknown-linux-gnu
# rust: 1.46.0 # MSRV
# - target: aarch64-unknown-linux-gnu
# rust: stable
#
# # PPC32
# - target: aarch64-unknown-linux-gnu
# rust: 1.46.0 # MSRV
# - target: powerpc-unknown-linux-gnu
# rust: stable
#
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v1
# - run: ${{ matrix.deps }}
# - uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# toolchain: ${{ matrix.rust }}
# target: ${{ matrix.target }}
# override: true
# - run: cargo install cross
# - run: cross test --release --target ${{ matrix.target }} --all-features
cross:
strategy:
matrix:
include:
# ARM64
- target: aarch64-unknown-linux-gnu
rust: 1.46.0 # MSRV
- target: aarch64-unknown-linux-gnu
rust: stable

# PPC32
- target: aarch64-unknown-linux-gnu
rust: 1.46.0 # MSRV
- target: powerpc-unknown-linux-gnu
rust: stable

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: ${{ matrix.deps }}
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
target: ${{ matrix.target }}
override: true
- run: cargo install cross
- run: cross test --release --target ${{ matrix.target }} --all-features
4 changes: 2 additions & 2 deletions k256/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ impl elliptic_curve::AlgorithmParameters for Secp256k1 {
const OID: pkcs8::ObjectIdentifier = pkcs8::ObjectIdentifier::new(&[1, 3, 132, 0, 10]);
}

/// Compressed SEC1-encoded secp256k1 (K-256) point (i.e. public key)
/// Compressed SEC1-encoded secp256k1 (K-256) point.
pub type CompressedPoint = [u8; 33];

/// secp256k1 (K-256) field element serialized as bytes.
Expand All @@ -133,7 +133,7 @@ pub type PublicKey = elliptic_curve::PublicKey<Secp256k1>;
#[cfg_attr(docsrs, doc(cfg(feature = "zeroize")))]
pub type SecretKey = elliptic_curve::SecretKey<Secp256k1>;

/// Bytes containing a secp256k1 secret scalar
/// Bytes containing a secp256k1 secret scalar.
#[cfg(feature = "zeroize")]
#[cfg_attr(docsrs, doc(cfg(feature = "zeroize")))]
pub type SecretBytes = elliptic_curve::secret_key::SecretBytes<Secp256k1>;
Expand Down

0 comments on commit c146760

Please sign in to comment.