Unverified Commit 805ebf7b authored by Wael Nasreddine's avatar Wael Nasreddine Committed by GitHub
Browse files

ncps: disable integration tests (#496074)

parents f2f71064 51666aee
Loading
Loading
Loading
Loading
+0 −31
Original line number Diff line number Diff line
@@ -6,14 +6,9 @@
  jq,
  lib,
  makeWrapper,
  mariadb,
  minio,
  minio-client,
  nix-update-script,
  nixosTests,
  postgresql,
  python3,
  redis,
  writeShellScriptBin,
  xz,
}:
@@ -44,16 +39,7 @@ buildGoModule (finalAttrs: {

  nativeBuildInputs = [
    makeWrapper # used for wrapping the binary so it can always find the xz binary

    curl # used for checking MinIO health check
    dbmate # used for testing
    jq # used for testing by the init-minio
    mariadb # MySQL/MariaDB for integration tests
    minio # S3-compatible storage for integration tests
    minio-client # mc CLI for MinIO setup
    postgresql # PostgreSQL for integration tests
    python3 # used for generating the ports
    redis # Redis for distributed locking integration tests
  ];

  postInstall = ''
@@ -78,23 +64,6 @@ buildGoModule (finalAttrs: {

  checkFlags = [ "-race" ];

  # pre and post checks
  preCheck = ''
    # Set up cleanup trap to ensure background processes are killed even if tests fail
    cleanup() {
      source $src/nix/packages/ncps/post-check-minio.sh
      source $src/nix/packages/ncps/post-check-mysql.sh
      source $src/nix/packages/ncps/post-check-postgres.sh
      source $src/nix/packages/ncps/post-check-redis.sh
    }
    trap cleanup EXIT

    source $src/nix/packages/ncps/pre-check-minio.sh
    source $src/nix/packages/ncps/pre-check-mysql.sh
    source $src/nix/packages/ncps/pre-check-postgres.sh
    source $src/nix/packages/ncps/pre-check-redis.sh
  '';

  passthru = {
    dbmate-wrapper = buildGoModule {
      pname = "ncps-dbmate-wrapper";