diff --git a/.github/actions/deploy-prod/action.yml b/.github/actions/deploy-prod/action.yml new file mode 100644 index 00000000..b2d32285 --- /dev/null +++ b/.github/actions/deploy-prod/action.yml @@ -0,0 +1,322 @@ +name: 'Deploy to Production (GitOps PR)' +description: 'Promotes a staging image to production by creating a PR in the production GitOps repository with full changelog and verification.' + +inputs: + SERVICE_NAME: + description: 'Service name (e.g., my-service)' + required: true + REASON: + description: 'Reason for this production deployment' + required: true + DRY_RUN: + description: 'Dry run mode - verify but do not create tag or PR' + required: false + default: 'false' + BRANCH_PREFIX: + description: 'Branch prefix for deployment PRs (default: SERVICE_NAME)' + required: false + default: '' + GITOPS_STAGING_REPO: + description: 'GitOps staging repository (e.g., org/repo-staging)' + required: true + GITOPS_PROD_REPO: + description: 'GitOps production repository (e.g., org/repo-prod)' + required: true + STACK_FILE_PATH: + description: 'Path to stack file in staging GitOps repo for reading current image (default: infrastructure/${SERVICE_NAME}.stack.yml). Also used for prod if PROD_STACK_FILE_PATHS is not set.' + required: false + default: '' + PROD_STACK_FILE_PATHS: + description: 'Comma-separated list of stack file paths in the PROD GitOps repo to update. If not set, uses STACK_FILE_PATH for prod as well.' + required: false + default: '' + DOCKER_REPOSITORY: + description: 'Docker repository (default: signalwire/${SERVICE_NAME})' + required: false + default: '' + SOURCE_REPO: + description: 'Source repository for commit comparison links (default: signalwire/${SERVICE_NAME})' + required: false + default: '' + BASE_BRANCH: + description: 'Base branch in the prod GitOps repo' + required: false + default: 'main' + +outputs: + new_tag: + description: 'The timestamp tag created on the source repo' + value: ${{ steps.create_tag.outputs.new_tag }} + pr_url: + description: 'URL of the deployment PR' + value: ${{ steps.create_pr.outputs.pr_url }} + staging_image_tag: + description: 'Production-ready image tag from staging' + value: ${{ steps.staging_info.outputs.prod_image_tag }} + previous_merged: + description: 'Whether previous deployment PR was merged' + value: ${{ steps.find_previous.outputs.previous_merged }} + +runs: + using: 'composite' + steps: + - name: Resolve defaults + id: defaults + shell: bash + env: + INPUT_SERVICE_NAME: ${{ inputs.SERVICE_NAME }} + INPUT_BRANCH_PREFIX: ${{ inputs.BRANCH_PREFIX }} + INPUT_STACK_FILE_PATH: ${{ inputs.STACK_FILE_PATH }} + INPUT_PROD_STACK_FILE_PATHS: ${{ inputs.PROD_STACK_FILE_PATHS }} + INPUT_DOCKER_REPOSITORY: ${{ inputs.DOCKER_REPOSITORY }} + INPUT_SOURCE_REPO: ${{ inputs.SOURCE_REPO }} + run: | + SERVICE_NAME="$INPUT_SERVICE_NAME" + + BRANCH_PREFIX="$INPUT_BRANCH_PREFIX" + if [[ -z "$BRANCH_PREFIX" ]]; then + BRANCH_PREFIX="${SERVICE_NAME}" + fi + + STACK_FILE="$INPUT_STACK_FILE_PATH" + if [[ -z "$STACK_FILE" ]]; then + STACK_FILE="infrastructure/${SERVICE_NAME}.stack.yml" + fi + + # PROD_STACK_FILE_PATHS: comma-separated list of prod stack files. + # If not set, fall back to STACK_FILE (same file for both staging and prod). + PROD_STACK_FILES="$INPUT_PROD_STACK_FILE_PATHS" + if [[ -z "$PROD_STACK_FILES" ]]; then + PROD_STACK_FILES="$STACK_FILE" + fi + + DOCKER_REPO="$INPUT_DOCKER_REPOSITORY" + if [[ -z "$DOCKER_REPO" ]]; then + DOCKER_REPO="signalwire/${SERVICE_NAME}" + fi + + SOURCE_REPO="$INPUT_SOURCE_REPO" + if [[ -z "$SOURCE_REPO" ]]; then + SOURCE_REPO="signalwire/${SERVICE_NAME}" + fi + + { + echo "branch_prefix=$BRANCH_PREFIX" + echo "stack_file=$STACK_FILE" + echo "prod_stack_files=$PROD_STACK_FILES" + echo "docker_repo=$DOCKER_REPO" + echo "source_repo=$SOURCE_REPO" + } >> "$GITHUB_OUTPUT" + + - name: Make scripts executable + shell: bash + run: chmod +x "${{ github.action_path }}/scripts/"*.sh + + - name: Get most recent production tag + id: get_tag + shell: bash + run: | + LATEST_TAG=$(git tag -l --sort=-creatordate | grep -E '^[0-9]{4}-[0-9]{2}-[0-9]{2}T' | head -1 || echo "") + echo "latest_tag=$LATEST_TAG" >> "$GITHUB_OUTPUT" + if [[ -n "$LATEST_TAG" ]]; then + echo "Latest existing production tag: $LATEST_TAG" + else + echo "No existing production tags found" + fi + + - name: Create new tag + id: create_tag + shell: bash + env: + DRY_RUN: ${{ inputs.DRY_RUN }} + ACTOR: ${{ github.actor }} + REASON: ${{ inputs.REASON }} + run: | + NEW_TAG=$(date -u +%FT%H-%M-%SZ) + + if [[ "$DRY_RUN" == "true" ]]; then + echo "DRY RUN: Would create tag $NEW_TAG" + echo "new_tag=$NEW_TAG" >> "$GITHUB_OUTPUT" + else + if git rev-parse "$NEW_TAG" >/dev/null 2>&1; then + echo "Tag $NEW_TAG already exists, reusing it" + else + # Write tag message to file to safely handle special characters. + TAG_MSG_FILE=$(mktemp) + printf "Production deployment by %s\n\n%s\n" "$ACTOR" "$REASON" > "$TAG_MSG_FILE" + git tag "$NEW_TAG" -a -F "$TAG_MSG_FILE" + rm -f "$TAG_MSG_FILE" + git push origin "$NEW_TAG" + echo "Created and pushed tag: $NEW_TAG" + fi + echo "new_tag=$NEW_TAG" >> "$GITHUB_OUTPUT" + fi + + - name: Checkout staging GitOps repo + uses: actions/checkout@v4 + with: + repository: ${{ inputs.GITOPS_STAGING_REPO }} + path: _staging + token: ${{ env.GITOPS_PAT_STAGING }} + + - name: Extract staging image info + id: staging_info + shell: bash + env: + ACTION_PATH: ${{ github.action_path }} + STACK_FILE: ${{ steps.defaults.outputs.stack_file }} + SERVICE_NAME: ${{ inputs.SERVICE_NAME }} + run: | + "${ACTION_PATH}/scripts/extract-staging-info.sh" \ + "_staging/${STACK_FILE}" \ + "$SERVICE_NAME" + + - name: Verify Docker image exists + shell: bash + env: + ACTION_PATH: ${{ github.action_path }} + DOCKER_REPO: ${{ steps.defaults.outputs.docker_repo }} + PROD_IMAGE_TAG: ${{ steps.staging_info.outputs.prod_image_tag }} + run: | + "${ACTION_PATH}/scripts/verify-docker-image.sh" \ + "$DOCKER_REPO" \ + "$PROD_IMAGE_TAG" + + - name: Checkout production GitOps repo + uses: actions/checkout@v4 + with: + repository: ${{ inputs.GITOPS_PROD_REPO }} + path: _prod + token: ${{ env.GITOPS_PAT_PROD }} + + - name: Get current production image info + id: prod_info + shell: bash + env: + PROD_STACK_FILES: ${{ steps.defaults.outputs.prod_stack_files }} + SERVICE_NAME: ${{ inputs.SERVICE_NAME }} + LATEST_TAG: ${{ steps.get_tag.outputs.latest_tag }} + run: | + # Use the first prod stack file for reading current state. + FIRST_PROD_FILE="${PROD_STACK_FILES%%,*}" + STACK_FILE_PATH="_prod/${FIRST_PROD_FILE}" + + # Use yq to extract current production image. + CURRENT_IMAGE=$(yq eval ' + .services[].image | select(contains("'"${SERVICE_NAME}"'")) + ' "$STACK_FILE_PATH" | head -1) + + if [[ -z "$CURRENT_IMAGE" ]]; then + CURRENT_IMAGE=$(grep -E "image:.*${SERVICE_NAME}" "$STACK_FILE_PATH" | head -1 | awk '{print $2}' | tr -d '"' | tr -d "'") + fi + + CURRENT_TAG="${CURRENT_IMAGE##*:}" + + CURRENT_SHA=$(yq eval ' + .. | select(has("GIT_SHA")).GIT_SHA + ' "$STACK_FILE_PATH" 2>/dev/null | head -1) + + if [[ -z "$CURRENT_SHA" || "$CURRENT_SHA" == "null" ]]; then + CURRENT_SHA=$(grep -E 'GIT_SHA' "$STACK_FILE_PATH" | head -1 | awk -F': ' '{print $NF}' | tr -d ' "' | tr -d "'") + fi + + # Fall back to the latest production tag if GIT_SHA is not in the stack file. + if [[ -z "$CURRENT_SHA" || "$CURRENT_SHA" == "null" ]]; then + if [[ -n "$LATEST_TAG" ]]; then + echo "::notice::GIT_SHA not found in prod stack file, using latest production tag: $LATEST_TAG" + CURRENT_SHA="$LATEST_TAG" + else + echo "::warning::Could not determine current production SHA (no GIT_SHA in stack file and no existing production tags)" + fi + fi + + echo "Current production image: ${CURRENT_TAG}" + echo "Current production SHA: ${CURRENT_SHA}" + + { + echo "current_tag=$CURRENT_TAG" + echo "current_sha=$CURRENT_SHA" + } >> "$GITHUB_OUTPUT" + + - name: Find previous deployment PR + id: find_previous + shell: bash + env: + GH_TOKEN: ${{ env.GITOPS_PAT_PROD }} + ACTION_PATH: ${{ github.action_path }} + GITOPS_PROD_REPO: ${{ inputs.GITOPS_PROD_REPO }} + BRANCH_PREFIX: ${{ steps.defaults.outputs.branch_prefix }} + run: | + "${ACTION_PATH}/scripts/find-previous-deploy-pr.sh" \ + "$GITOPS_PROD_REPO" \ + "$BRANCH_PREFIX" + + - name: Get PRs between commits + id: get_prs + shell: bash + env: + GH_TOKEN: ${{ env.SOURCE_REPO_TOKEN }} + ACTION_PATH: ${{ github.action_path }} + CURRENT_SHA: ${{ steps.prod_info.outputs.current_sha }} + STAGING_GIT_SHA: ${{ steps.staging_info.outputs.git_sha }} + SOURCE_REPO: ${{ steps.defaults.outputs.source_repo }} + run: | + "${ACTION_PATH}/scripts/get-prs-between-commits.sh" \ + "$CURRENT_SHA" \ + "$STAGING_GIT_SHA" \ + "$SOURCE_REPO" + + - name: Create deployment branch and PR + id: create_pr + shell: bash + env: + GH_TOKEN: ${{ env.GITOPS_PAT_PROD }} + DRY_RUN: ${{ inputs.DRY_RUN }} + ACTION_PATH: ${{ github.action_path }} + SERVICE_NAME: ${{ inputs.SERVICE_NAME }} + BRANCH_PREFIX: ${{ steps.defaults.outputs.branch_prefix }} + NEW_TAG: ${{ steps.create_tag.outputs.new_tag }} + NEW_IMAGE_TAG: ${{ steps.staging_info.outputs.prod_image_tag }} + NEW_SHA: ${{ steps.staging_info.outputs.git_sha }} + OLD_IMAGE_TAG: ${{ steps.prod_info.outputs.current_tag }} + OLD_SHA: ${{ steps.prod_info.outputs.current_sha }} + GITOPS_PROD_REPO: ${{ inputs.GITOPS_PROD_REPO }} + SOURCE_REPO: ${{ steps.defaults.outputs.source_repo }} + PROD_STACK_FILES: ${{ steps.defaults.outputs.prod_stack_files }} + DOCKER_REPO: ${{ steps.defaults.outputs.docker_repo }} + BASE_BRANCH: ${{ inputs.BASE_BRANCH }} + DEPLOY_REASON: ${{ inputs.REASON }} + PR_LIST: ${{ steps.get_prs.outputs.pr_list }} + working-directory: _prod + run: | + DRY_RUN_FLAG="" + if [[ "$DRY_RUN" == "true" ]]; then + DRY_RUN_FLAG="--dry-run" + fi + + # Build --stack-file arguments for each prod file. + STACK_FILE_ARGS="" + IFS=',' read -ra FILES <<< "$PROD_STACK_FILES" + for f in "${FILES[@]}"; do + f="$(echo "$f" | xargs)" # trim whitespace + STACK_FILE_ARGS="$STACK_FILE_ARGS --stack-file $f" + done + + "${ACTION_PATH}/scripts/create-prod-pr.sh" \ + --service-name "$SERVICE_NAME" \ + --branch-name "${BRANCH_PREFIX}/${NEW_TAG}" \ + --new-image-tag "$NEW_IMAGE_TAG" \ + --new-sha "$NEW_SHA" \ + --old-image-tag "$OLD_IMAGE_TAG" \ + --old-sha "$OLD_SHA" \ + --repo "$GITOPS_PROD_REPO" \ + --source-repo "$SOURCE_REPO" \ + $STACK_FILE_ARGS \ + --docker-repo "$DOCKER_REPO" \ + --base-branch "$BASE_BRANCH" \ + $DRY_RUN_FLAG + + - name: Clean up checkout directories + if: always() + shell: bash + run: rm -rf _staging _prod diff --git a/.github/actions/deploy-prod/scripts/create-prod-pr.sh b/.github/actions/deploy-prod/scripts/create-prod-pr.sh new file mode 100755 index 00000000..b3731163 --- /dev/null +++ b/.github/actions/deploy-prod/scripts/create-prod-pr.sh @@ -0,0 +1,196 @@ +#!/bin/bash +# Create a production deployment branch and PR in a GitOps repository. +# +# Usage: ./create-prod-pr.sh [options] +# --service-name NAME Service name (e.g., my-service) +# --branch-name NAME Branch name for the PR (e.g., my-service/2026-01-28T10-30-00Z) +# --new-image-tag TAG New Docker image tag +# --new-sha SHA New git SHA +# --old-image-tag TAG Previous Docker image tag +# --old-sha SHA Previous git SHA +# --repo REPO Target GitOps repo (e.g., org/gitops-prod) +# --source-repo REPO Source repo for comparison links (e.g., org/my-service) +# --stack-file PATH Path to stack file in GitOps repo (can be specified multiple times) +# --docker-repo REPO Docker repository (e.g., org/my-service) +# --base-branch BRANCH Base branch for PR (default: main) +# --dry-run Show what would be done without creating PR +# +# Environment variables (for multiline content): +# DEPLOY_REASON Reason for deployment +# PR_LIST Markdown list of PRs included + +set -euo pipefail + +DRY_RUN=false +SERVICE_NAME="" +BRANCH_NAME="" +NEW_IMAGE_TAG="" +NEW_SHA="" +OLD_IMAGE_TAG="" +OLD_SHA="" +REPO="" +SOURCE_REPO="" +STACK_FILES=() +DOCKER_REPO="" +BASE_BRANCH="main" + +while [[ $# -gt 0 ]]; do + case $1 in + --service-name) SERVICE_NAME="$2"; shift 2 ;; + --branch-name) BRANCH_NAME="$2"; shift 2 ;; + --new-image-tag) NEW_IMAGE_TAG="$2"; shift 2 ;; + --new-sha) NEW_SHA="$2"; shift 2 ;; + --old-image-tag) OLD_IMAGE_TAG="$2"; shift 2 ;; + --old-sha) OLD_SHA="$2"; shift 2 ;; + --repo) REPO="$2"; shift 2 ;; + --source-repo) SOURCE_REPO="$2"; shift 2 ;; + --stack-file) STACK_FILES+=("$2"); shift 2 ;; + --docker-repo) DOCKER_REPO="$2"; shift 2 ;; + --base-branch) BASE_BRANCH="$2"; shift 2 ;; + --dry-run) DRY_RUN=true; shift ;; + *) echo "::error::Unknown option: $1"; exit 1 ;; + esac +done + +REASON="${DEPLOY_REASON:-}" +PR_LIST_CONTENT="${PR_LIST:-}" + +: "${SERVICE_NAME:?--service-name is required}" +: "${BRANCH_NAME:?--branch-name is required}" +: "${NEW_IMAGE_TAG:?--new-image-tag is required}" +: "${NEW_SHA:?--new-sha is required}" +: "${OLD_IMAGE_TAG:?--old-image-tag is required}" +: "${OLD_SHA:?--old-sha is required}" +: "${REASON:?DEPLOY_REASON environment variable is required}" +: "${REPO:?--repo is required}" +if [[ ${#STACK_FILES[@]} -eq 0 ]]; then + echo "::error::--stack-file is required (at least one)" + exit 1 +fi + +: "${DOCKER_REPO:?--docker-repo is required}" +: "${SOURCE_REPO:?--source-repo is required}" + +if [[ -z "$PR_LIST_CONTENT" ]]; then + PR_LIST_CONTENT="*No PRs found between versions*" +fi + +# Check if branch already exists. +if git ls-remote --exit-code --heads origin "$BRANCH_NAME" >/dev/null 2>&1; then + echo "::error::Branch $BRANCH_NAME already exists in $REPO." + echo "A deployment PR may already be open: https://github.com/${REPO}/pulls?q=is%3Apr+head%3A${BRANCH_NAME}" + exit 1 +fi + +git config user.name "github-actions[bot]" +git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + +if [[ "$DRY_RUN" == "true" ]]; then + echo "=== DRY RUN MODE ===" + echo "" + echo "Would create branch: $BRANCH_NAME" + for STACK_FILE in "${STACK_FILES[@]}"; do + echo "Would update file: $STACK_FILE" + echo " - image: ${DOCKER_REPO}:${NEW_IMAGE_TAG}" + echo " - GIT_SHA: ${NEW_SHA}" + done + echo "" +else + git checkout -b "$BRANCH_NAME" + + for STACK_FILE in "${STACK_FILES[@]}"; do + echo "Updating $STACK_FILE ..." + + # Update image tag using yq for proper YAML handling. + # Find and update any image value matching the docker repo. + yq eval -i " + (.services[].image | select(contains(\"${SERVICE_NAME}\"))) = \"${DOCKER_REPO}:${NEW_IMAGE_TAG}\" + " "$STACK_FILE" + + # Update GIT_SHA in environment sections. + yq eval -i " + (.. | select(has(\"GIT_SHA\")).GIT_SHA) = \"${NEW_SHA}\" + " "$STACK_FILE" + + git add "$STACK_FILE" + done + + git commit -m "[${SERVICE_NAME}] Update image to ${DOCKER_REPO}:${NEW_IMAGE_TAG}" + git push origin "$BRANCH_NAME" +fi + +# Build list of updated files for PR body. +FILES_LIST="" +for STACK_FILE in "${STACK_FILES[@]}"; do + FILES_LIST="${FILES_LIST} +- \`${STACK_FILE}\`" +done + +# Build PR body with rich deployment context. +PR_BODY="## :rocket: Production Deployment: ${SERVICE_NAME} + +### Image Info + +| | Image | GIT_SHA | +|---|---|---| +| **New** | \`${DOCKER_REPO}:${NEW_IMAGE_TAG}\` | \`${NEW_SHA}\` | +| **Previous** | \`${DOCKER_REPO}:${OLD_IMAGE_TAG}\` | \`${OLD_SHA}\` | + +### Reason for Deploy + +${REASON} + +### Changes + +:mag: [Full Commit Comparison](https://github.com/${SOURCE_REPO}/compare/${OLD_SHA}...${NEW_SHA}) + +#### Pull Requests Included + +${PR_LIST_CONTENT} + +### Stack Files Updated +${FILES_LIST} + +### Pre-Merge Checklist + +- [ ] Verified the Docker image exists and is ready for production +- [ ] Reviewed the included PRs for any deployment-sensitive changes +- [ ] Confirmed no conflicting deployments are in progress +- [ ] Service name is in the PR/commit title (for deployment channel visibility) + +--- +*This PR was automatically generated by the deploy-prod workflow.*" + +PR_TITLE="[${SERVICE_NAME}] Update image to ${DOCKER_REPO}:${NEW_IMAGE_TAG}" + +if [[ "$DRY_RUN" == "true" ]]; then + echo "Would create PR:" + echo " Title: $PR_TITLE" + echo " Base: $BASE_BRANCH" + echo " Head: $BRANCH_NAME" + echo "" + echo "PR Body:" + echo "==========================================" + echo "$PR_BODY" + echo "==========================================" + echo "" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "pr_url=DRY_RUN_NO_PR_CREATED" >> "$GITHUB_OUTPUT" + fi +else + PR_BODY_FILE=$(mktemp) + echo "$PR_BODY" > "$PR_BODY_FILE" + + PR_URL=$(gh pr create \ + --repo "$REPO" \ + --title "$PR_TITLE" \ + --body-file "$PR_BODY_FILE" \ + --base "$BASE_BRANCH" \ + --head "$BRANCH_NAME") + + rm -f "$PR_BODY_FILE" + echo "Created PR: $PR_URL" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "pr_url=$PR_URL" >> "$GITHUB_OUTPUT" + fi +fi diff --git a/.github/actions/deploy-prod/scripts/extract-staging-info.sh b/.github/actions/deploy-prod/scripts/extract-staging-info.sh new file mode 100755 index 00000000..beea396d --- /dev/null +++ b/.github/actions/deploy-prod/scripts/extract-staging-info.sh @@ -0,0 +1,71 @@ +#!/bin/bash +# Extract image tag and GIT_SHA from a staging stack file using yq. +# +# Usage: ./extract-staging-info.sh +# +# Outputs (via GITHUB_OUTPUT): +# full_image - Full image reference (e.g., org/my-service:staging-20260129-765-2cb19ef) +# image_tag - Raw tag from stack file (e.g., staging-20260129-765-2cb19ef) +# prod_image_tag - Production-ready tag with staging- prefix stripped (e.g., 20260129-765-2cb19ef) +# git_sha - GIT_SHA value from the stack file environment + +set -euo pipefail + +STACK_FILE="${1:?Usage: extract-staging-info.sh }" +SERVICE_NAME="${2:?Usage: extract-staging-info.sh }" + +if [[ ! -f "$STACK_FILE" ]]; then + echo "::error::Stack file not found: $STACK_FILE" + exit 1 +fi + +# Use yq to extract the image for the service. +# Stack files use docker-compose format: services..image +# We search for any service whose image matches the service name pattern. +FULL_IMAGE=$(yq eval ' + .services[].image | select(contains("'"${SERVICE_NAME}"'")) +' "$STACK_FILE" | head -1) + +# Fallback: if yq finds nothing (e.g., image is under a different structure), +# try a targeted grep as last resort. +if [[ -z "$FULL_IMAGE" ]]; then + FULL_IMAGE=$(grep -E "image:.*${SERVICE_NAME}" "$STACK_FILE" | head -1 | awk '{print $2}' | tr -d '"' | tr -d "'") +fi + +if [[ -z "$FULL_IMAGE" ]]; then + echo "::error::Could not extract image for ${SERVICE_NAME} from $STACK_FILE" + exit 1 +fi + +IMAGE_TAG="${FULL_IMAGE##*:}" +PROD_IMAGE_TAG="${IMAGE_TAG#staging-}" + +# Extract GIT_SHA from the environment section. +# Try yq first for structured parsing. +GIT_SHA=$(yq eval ' + .. | select(has("GIT_SHA")).GIT_SHA +' "$STACK_FILE" 2>/dev/null | head -1) + +# Fallback for non-standard formats. +if [[ -z "$GIT_SHA" || "$GIT_SHA" == "null" ]]; then + GIT_SHA=$(grep -E 'GIT_SHA' "$STACK_FILE" | head -1 | awk -F': ' '{print $NF}' | tr -d ' "' | tr -d "'") +fi + +if [[ -z "$GIT_SHA" || "$GIT_SHA" == "null" ]]; then + echo "::error::Could not extract GIT_SHA from $STACK_FILE" + exit 1 +fi + +echo "Staging image: $FULL_IMAGE" +echo "Image tag: $IMAGE_TAG" +echo "Production tag: $PROD_IMAGE_TAG" +echo "GIT_SHA: $GIT_SHA" + +if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + { + echo "full_image=$FULL_IMAGE" + echo "image_tag=$IMAGE_TAG" + echo "prod_image_tag=$PROD_IMAGE_TAG" + echo "git_sha=$GIT_SHA" + } >> "$GITHUB_OUTPUT" +fi diff --git a/.github/actions/deploy-prod/scripts/find-previous-deploy-pr.sh b/.github/actions/deploy-prod/scripts/find-previous-deploy-pr.sh new file mode 100755 index 00000000..89c9eef4 --- /dev/null +++ b/.github/actions/deploy-prod/scripts/find-previous-deploy-pr.sh @@ -0,0 +1,95 @@ +#!/bin/bash +# Find previous deployment PRs for a service in a GitOps repo. +# +# Usage: ./find-previous-deploy-pr.sh +# Example: ./find-previous-deploy-pr.sh org/gitops-prod my-service/ +# +# Requires: GH_TOKEN environment variable with repo read access. +# +# Outputs (via GITHUB_OUTPUT): +# last_pr_number - Number of the most recent deployment PR +# last_pr_state - State of that PR (OPEN, CLOSED, MERGED) +# last_pr_branch - Head branch of that PR +# previous_merged - "true" if last PR was merged, "false" if not, "unknown" if none found +# last_merged_pr_number - Number of the last actually merged PR (if the latest wasn't merged) + +set -euo pipefail + +REPO="${1:?Usage: find-previous-deploy-pr.sh }" +BRANCH_PREFIX="${2:?Usage: find-previous-deploy-pr.sh }" + +# Ensure trailing slash on prefix for consistent matching. +BRANCH_PREFIX="${BRANCH_PREFIX%/}/" + +echo "Searching for previous ${BRANCH_PREFIX}* PRs in $REPO..." + +# Query PRs using the service name as a broad search term. +# The jq filter below does precise matching on headRefName, so +# the search just needs to return a superset that includes our PRs. +# gh returns non-zero on auth failures - fail fast in that case. +SEARCH_TERM="${BRANCH_PREFIX%/}" +PREVIOUS_PRS=$(gh pr list \ + --repo "$REPO" \ + --state all \ + --limit 50 \ + --search "$SEARCH_TERM sort:created-desc" \ + --json number,headRefName,state,mergedAt,title 2>&1) || { + echo "::error::Failed to query PRs from $REPO. Check GH_TOKEN permissions." + echo "gh output: $PREVIOUS_PRS" + exit 1 + } + +# Sort by PR number descending and find the most recent one matching the branch prefix. +LAST_PR=$(echo "$PREVIOUS_PRS" \ + | jq -r "[.[] | select(.headRefName | startswith(\"$BRANCH_PREFIX\"))] | sort_by(.number) | reverse | first") + +if [[ "$LAST_PR" == "null" || -z "$LAST_PR" ]]; then + echo "No previous ${BRANCH_PREFIX}* PRs found (this may be the first automated deployment)" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "previous_merged=unknown" >> "$GITHUB_OUTPUT" + fi + exit 0 +fi + +LAST_PR_NUMBER=$(echo "$LAST_PR" | jq -r '.number') +LAST_PR_STATE=$(echo "$LAST_PR" | jq -r '.state') +LAST_PR_BRANCH=$(echo "$LAST_PR" | jq -r '.headRefName') +LAST_PR_MERGED_AT=$(echo "$LAST_PR" | jq -r '.mergedAt') + +echo "Most recent PR: #$LAST_PR_NUMBER ($LAST_PR_BRANCH) - state: $LAST_PR_STATE" + +if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + { + echo "last_pr_number=$LAST_PR_NUMBER" + echo "last_pr_state=$LAST_PR_STATE" + echo "last_pr_branch=$LAST_PR_BRANCH" + } >> "$GITHUB_OUTPUT" +fi + +if [[ "$LAST_PR_STATE" == "MERGED" ]]; then + echo "Previous PR #$LAST_PR_NUMBER was merged on $LAST_PR_MERGED_AT" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "previous_merged=true" >> "$GITHUB_OUTPUT" + fi +else + echo "::warning::Previous PR #$LAST_PR_NUMBER ($LAST_PR_BRANCH) was NOT merged (state: $LAST_PR_STATE)" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "previous_merged=false" >> "$GITHUB_OUTPUT" + fi + + # Find the last actually merged PR for context. + LAST_MERGED=$(echo "$PREVIOUS_PRS" \ + | jq -r "[.[] | select(.headRefName | startswith(\"$BRANCH_PREFIX\")) | select(.state == \"MERGED\")] | sort_by(.number) | reverse | first") + + if [[ "$LAST_MERGED" != "null" && -n "$LAST_MERGED" ]]; then + LAST_MERGED_NUMBER=$(echo "$LAST_MERGED" | jq -r '.number') + LAST_MERGED_BRANCH=$(echo "$LAST_MERGED" | jq -r '.headRefName') + echo "::warning::Last actually merged PR was #$LAST_MERGED_NUMBER ($LAST_MERGED_BRANCH)" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + { + echo "last_merged_pr_number=$LAST_MERGED_NUMBER" + echo "last_merged_pr_branch=$LAST_MERGED_BRANCH" + } >> "$GITHUB_OUTPUT" + fi + fi +fi diff --git a/.github/actions/deploy-prod/scripts/get-prs-between-commits.sh b/.github/actions/deploy-prod/scripts/get-prs-between-commits.sh new file mode 100755 index 00000000..6ffadd29 --- /dev/null +++ b/.github/actions/deploy-prod/scripts/get-prs-between-commits.sh @@ -0,0 +1,80 @@ +#!/bin/bash +# Get the list of PRs merged between two commits in a source repository. +# +# Usage: ./get-prs-between-commits.sh +# Example: ./get-prs-between-commits.sh abc123 def456 org/my-service +# +# Requires: GH_TOKEN environment variable. +# Must be run from within the source repo checkout (with full git history). +# +# Outputs (via GITHUB_OUTPUT): +# pr_list - Markdown-formatted list of PRs between the two commits. + +set -euo pipefail + +OLD_SHA="${1:?Usage: get-prs-between-commits.sh }" +NEW_SHA="${2:?Usage: get-prs-between-commits.sh }" +SOURCE_REPO="${3:?Usage: get-prs-between-commits.sh }" + +echo "Finding PRs between $OLD_SHA and $NEW_SHA in $SOURCE_REPO" + +PR_LINES="" +TOTAL_COMMITS="" + +# Try using the GitHub compare API first (works regardless of local git history depth). +# Cache the full response to avoid duplicate API calls. +COMPARE_JSON=$(gh api "repos/${SOURCE_REPO}/compare/${OLD_SHA}...${NEW_SHA}" 2>/dev/null || echo "") + +if [[ -n "$COMPARE_JSON" ]]; then + TOTAL_COMMITS=$(echo "$COMPARE_JSON" | jq -r '.total_commits // 0') + + # Filter to merge commits only (commits with >1 parent) to avoid picking up + # issue references and other #NNN patterns from non-merge commit messages. + MERGE_MESSAGES=$(echo "$COMPARE_JSON" \ + | jq -r '[.commits[] | select(.parents | length > 1)] | .[].commit.message' 2>/dev/null || echo "") + + if [[ -n "$MERGE_MESSAGES" ]]; then + PR_NUMBERS=$(echo "$MERGE_MESSAGES" | grep -oE '#[0-9]+' | tr -d '#' | sort -un || echo "") + else + PR_NUMBERS="" + fi +else + # Fallback: use local git history if the API call fails. + echo "GitHub compare API unavailable, falling back to local git history" + MERGE_COMMITS=$(git log --oneline --merges "${OLD_SHA}..${NEW_SHA}" 2>/dev/null | head -50 || echo "") + PR_NUMBERS=$(echo "$MERGE_COMMITS" | grep -oE '#[0-9]+' | tr -d '#' | sort -un || echo "") +fi + +# Fetch PR details for each found PR number. +for PR_NUM in $PR_NUMBERS; do + PR_INFO=$(gh pr view "$PR_NUM" --repo "$SOURCE_REPO" --json number,title 2>/dev/null || echo "") + if [[ -n "$PR_INFO" ]]; then + PR_TITLE=$(echo "$PR_INFO" | jq -r '.title') + PR_LINES="${PR_LINES}- [#${PR_NUM}](https://github.com/${SOURCE_REPO}/pull/${PR_NUM}) - ${PR_TITLE} +" + fi +done + +# If no PRs were found, provide a commit count summary. +if [[ -z "$PR_LINES" ]]; then + if [[ -z "$TOTAL_COMMITS" ]]; then + TOTAL_COMMITS=$(git rev-list --count "${OLD_SHA}..${NEW_SHA}" 2>/dev/null || echo "0") + fi + + if [[ "$TOTAL_COMMITS" -gt 0 ]] 2>/dev/null; then + PR_LINES="*${TOTAL_COMMITS} commits between versions (see comparison link above for details)*" + else + PR_LINES="*No commits found between versions*" + fi +fi + +echo "Found PRs:" +echo "$PR_LINES" + +if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + { + echo "pr_list<> "$GITHUB_OUTPUT" +fi diff --git a/.github/actions/deploy-prod/scripts/verify-docker-image.sh b/.github/actions/deploy-prod/scripts/verify-docker-image.sh new file mode 100755 index 00000000..7eebb02c --- /dev/null +++ b/.github/actions/deploy-prod/scripts/verify-docker-image.sh @@ -0,0 +1,43 @@ +#!/bin/bash +# Verify a Docker image exists without pulling it. +# +# Usage: ./verify-docker-image.sh +# Example: ./verify-docker-image.sh org/my-service 20260129-765-2cb19ef +# +# Requires: Docker login for private repositories (use docker/login-action in workflow). + +set -euo pipefail + +REPOSITORY="${1:?Usage: verify-docker-image.sh }" +TAG="${2:?Usage: verify-docker-image.sh }" + +echo "Verifying image ${REPOSITORY}:${TAG} exists..." + +# Try docker manifest inspect first (works for private repos when authenticated). +if docker manifest inspect "${REPOSITORY}:${TAG}" > /dev/null 2>&1; then + echo "Docker image ${REPOSITORY}:${TAG} verified via manifest inspect" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "image_exists=true" >> "$GITHUB_OUTPUT" + fi + exit 0 +fi + +# Fallback: Docker Hub API (works for public repos without auth). +HTTP_STATUS=$(curl -s -o /dev/null -w "%{http_code}" \ + "https://hub.docker.com/v2/repositories/${REPOSITORY}/tags/${TAG}" 2>/dev/null || echo "000") + +if [[ "$HTTP_STATUS" == "200" ]]; then + echo "Docker image ${REPOSITORY}:${TAG} verified via Docker Hub API" + if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "image_exists=true" >> "$GITHUB_OUTPUT" + fi + exit 0 +fi + +echo "::error::Docker image ${REPOSITORY}:${TAG} not found" +echo " - docker manifest inspect: failed (not logged in or image does not exist)" +echo " - Docker Hub API: HTTP $HTTP_STATUS" +if [[ -n "${GITHUB_OUTPUT:-}" ]]; then + echo "image_exists=false" >> "$GITHUB_OUTPUT" +fi +exit 1 diff --git a/.github/actions/update-gitops/action.yml b/.github/actions/update-gitops/action.yml index eb54a056..c4d16419 100644 --- a/.github/actions/update-gitops/action.yml +++ b/.github/actions/update-gitops/action.yml @@ -30,6 +30,13 @@ inputs: GH_TOKEN: required: false description: GitHub Token for authentication + GIT_SHA: + required: false + description: 'Git SHA to update in the stack file' + DRY_RUN: + required: false + default: 'false' + description: 'Verify changes without pushing' runs: using: "composite" @@ -76,6 +83,7 @@ runs: SERVICE_NAME: ${{ inputs.SERVICE_NAME }} IMAGE_TAG: ${{ inputs.IMAGE_TAG }} SWARM_SERVICE_NAME: ${{ inputs.SWARM_SERVICE_NAME }} + GIT_SHA: ${{ inputs.GIT_SHA }} working-directory: gitops run: | set -x @@ -93,9 +101,17 @@ runs: sed -i "s|image: signalwire/${SERVICE_NAME}:[^ ]*|image: ${IMAGE_TAG}|" "$FILE_PATH" fi + if [ -n "$GIT_SHA" ]; then + if [ -n "$SWARM_SERVICE_NAME" ]; then + sed -i "/^ ${SWARM_SERVICE_NAME}:/,/^ [^[:space:]]/ s|GIT_SHA: [^ ]*|GIT_SHA: $GIT_SHA|" "$FILE_PATH" + else + sed -i "s|GIT_SHA: [^ ]*|GIT_SHA: $GIT_SHA|" "$FILE_PATH" + fi + fi + git status git diff - + - name: Update image tag in GitOps repo for Kubernetes shell: bash if: ${{ inputs.ORCHESTRATOR == 'kubernetes' }} @@ -108,6 +124,7 @@ runs: - name: Create commit shell: bash + if: inputs.DRY_RUN != 'true' working-directory: gitops run: | git config user.name github-actions[bot] @@ -122,14 +139,14 @@ runs: - name: Push changes shell: bash - if: inputs.CREATE_PR == 'false' + if: inputs.CREATE_PR == 'false' && inputs.DRY_RUN != 'true' working-directory: gitops run: | git push - name: Create PR shell: bash - if: inputs.CREATE_PR == 'true' + if: inputs.CREATE_PR == 'true' && inputs.DRY_RUN != 'true' working-directory: gitops env: GH_TOKEN: ${{ inputs.GH_TOKEN }} diff --git a/.github/workflows/cd-deploy-prod.yml b/.github/workflows/cd-deploy-prod.yml new file mode 100644 index 00000000..268e63d8 --- /dev/null +++ b/.github/workflows/cd-deploy-prod.yml @@ -0,0 +1,221 @@ +name: Deploy to Production (GitOps PR) + +on: + workflow_call: + inputs: + SERVICE_NAME: + required: true + type: string + description: 'Service name (e.g., my-service, my-app). Used for image naming, stack file paths, and PR titles.' + REASON: + required: true + type: string + description: 'Reason for this production deployment (included in PR body and tag annotation).' + DRY_RUN: + required: false + type: boolean + default: false + description: 'Dry run mode - verify everything but do not create tag or PR.' + BRANCH_PREFIX: + required: false + type: string + default: '' + description: 'Branch prefix for deployment PRs in the prod GitOps repo (default: SERVICE_NAME).' + GITOPS_STAGING_REPO: + required: true + type: string + description: 'GitOps staging repository to read current staging image from (e.g., org/repo-staging).' + GITOPS_PROD_REPO: + required: true + type: string + description: 'GitOps production repository to create deployment PR in (e.g., org/repo-prod).' + STACK_FILE_PATH: + required: false + type: string + default: '' + description: 'Path to stack file in staging GitOps repo for reading current image (default: infrastructure/${SERVICE_NAME}.stack.yml). Also used for prod if PROD_STACK_FILE_PATHS is not set.' + PROD_STACK_FILE_PATHS: + required: false + type: string + default: '' + description: 'Comma-separated list of stack file paths in the PROD GitOps repo to update. If not set, uses STACK_FILE_PATH for prod as well. Useful when prod has multiple files (e.g., per-region stacks).' + DOCKER_REPOSITORY: + required: false + type: string + default: '' + description: 'Docker repository for image verification (default: signalwire/${SERVICE_NAME}).' + SOURCE_REPO: + required: false + type: string + default: '' + description: 'Source repository for commit comparison links (default: signalwire/${SERVICE_NAME}).' + BASE_BRANCH: + required: false + type: string + default: 'main' + description: 'Base branch in the prod GitOps repo for PR creation.' + RUNNER: + required: false + type: string + default: 'ubuntu-latest' + description: 'Runner to use for the deployment job.' + ACTIONS_REF: + required: false + type: string + default: 'main' + description: 'Ref of signalwire/actions-template to use. Override to test action changes on a branch.' + NOTIFY_SLACK: + required: false + type: boolean + default: false + description: 'Send Slack notification on deployment PR creation.' + SLACK_CHANNEL: + required: false + type: string + default: '' + description: 'Slack channel for deployment notifications.' + secrets: + GITOPS_PAT_STAGING: + required: true + description: 'PAT with read access to the staging GitOps repo.' + GITOPS_PAT_PROD: + required: true + description: 'PAT with read/write access to the production GitOps repo (branch creation + PR).' + DOCKERHUB_USERNAME: + required: true + description: 'Docker Hub username for image verification.' + DOCKERHUB_TOKEN: + required: true + description: 'Docker Hub token for image verification.' + SLACK_WEBHOOK_URL: + required: false + description: 'Slack webhook URL for deployment notifications.' + outputs: + NEW_TAG: + description: 'The timestamp tag created on the source repo.' + value: ${{ jobs.deploy-prod.outputs.new_tag }} + PR_URL: + description: 'URL of the deployment PR created in the prod GitOps repo.' + value: ${{ jobs.deploy-prod.outputs.pr_url }} + STAGING_IMAGE_TAG: + description: 'The image tag extracted from staging (production-ready, staging- prefix stripped).' + value: ${{ jobs.deploy-prod.outputs.staging_image_tag }} + PREVIOUS_MERGED: + description: 'Whether the previous deployment PR for this service was merged.' + value: ${{ jobs.deploy-prod.outputs.previous_merged }} + +jobs: + deploy-prod: + name: 'Create Production Deployment PR' + runs-on: ${{ inputs.RUNNER }} + permissions: + contents: write + outputs: + new_tag: ${{ steps.deploy.outputs.new_tag }} + pr_url: ${{ steps.deploy.outputs.pr_url }} + staging_image_tag: ${{ steps.deploy.outputs.staging_image_tag }} + previous_merged: ${{ steps.deploy.outputs.previous_merged }} + + steps: + - name: Checkout source repo + uses: actions/checkout@v4 + with: + fetch-depth: 0 + fetch-tags: true + + - name: Checkout actions-template + uses: actions/checkout@v4 + with: + repository: signalwire/actions-template + ref: ${{ inputs.ACTIONS_REF }} + path: actions + + - name: Install yq + uses: mikefarah/yq@2be0094729a1006f61e8339ce9934bfb3cbb549f # v4.52.2 + + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: Run deploy-prod action + id: deploy + uses: ./actions/.github/actions/deploy-prod + with: + SERVICE_NAME: ${{ inputs.SERVICE_NAME }} + REASON: ${{ inputs.REASON }} + DRY_RUN: ${{ inputs.DRY_RUN }} + BRANCH_PREFIX: ${{ inputs.BRANCH_PREFIX }} + GITOPS_STAGING_REPO: ${{ inputs.GITOPS_STAGING_REPO }} + GITOPS_PROD_REPO: ${{ inputs.GITOPS_PROD_REPO }} + STACK_FILE_PATH: ${{ inputs.STACK_FILE_PATH }} + PROD_STACK_FILE_PATHS: ${{ inputs.PROD_STACK_FILE_PATHS }} + DOCKER_REPOSITORY: ${{ inputs.DOCKER_REPOSITORY }} + SOURCE_REPO: ${{ inputs.SOURCE_REPO }} + BASE_BRANCH: ${{ inputs.BASE_BRANCH }} + env: + GH_TOKEN: ${{ secrets.GITOPS_PAT_PROD }} + GITOPS_PAT_STAGING: ${{ secrets.GITOPS_PAT_STAGING }} + GITOPS_PAT_PROD: ${{ secrets.GITOPS_PAT_PROD }} + SOURCE_REPO_TOKEN: ${{ github.token }} + + - name: Job Summary + if: always() + shell: bash + env: + DRY_RUN: ${{ inputs.DRY_RUN }} + SERVICE_NAME: ${{ inputs.SERVICE_NAME }} + NEW_TAG: ${{ steps.deploy.outputs.new_tag }} + PR_URL: ${{ steps.deploy.outputs.pr_url }} + STAGING_TAG: ${{ steps.deploy.outputs.staging_image_tag }} + PREV_MERGED: ${{ steps.deploy.outputs.previous_merged }} + DOCKER_REPO: ${{ inputs.DOCKER_REPOSITORY }} + REASON: ${{ inputs.REASON }} + run: | + if [[ -z "$DOCKER_REPO" ]]; then + DOCKER_REPO="signalwire/${SERVICE_NAME}" + fi + + if [[ "$DRY_RUN" == "true" ]]; then + echo "## Production Deployment (DRY RUN)" >> "$GITHUB_STEP_SUMMARY" + echo "" >> "$GITHUB_STEP_SUMMARY" + echo ":test_tube: **This was a dry run - no changes were made**" >> "$GITHUB_STEP_SUMMARY" + else + echo "## Production Deployment" >> "$GITHUB_STEP_SUMMARY" + fi + + echo "" >> "$GITHUB_STEP_SUMMARY" + echo "| Field | Value |" >> "$GITHUB_STEP_SUMMARY" + echo "|-------|-------|" >> "$GITHUB_STEP_SUMMARY" + echo "| **Service** | \`${SERVICE_NAME}\` |" >> "$GITHUB_STEP_SUMMARY" + echo "| **Tag** | \`${NEW_TAG}\` |" >> "$GITHUB_STEP_SUMMARY" + echo "| **Image** | \`${DOCKER_REPO}:${STAGING_TAG}\` |" >> "$GITHUB_STEP_SUMMARY" + + if [[ "$DRY_RUN" != "true" && -n "$PR_URL" ]]; then + echo "| **PR** | ${PR_URL} |" >> "$GITHUB_STEP_SUMMARY" + fi + + echo "" >> "$GITHUB_STEP_SUMMARY" + echo "### Previous Deployment Status" >> "$GITHUB_STEP_SUMMARY" + + if [[ "$PREV_MERGED" == "false" ]]; then + echo ":warning: Previous deployment PR was **NOT merged**" >> "$GITHUB_STEP_SUMMARY" + elif [[ "$PREV_MERGED" == "true" ]]; then + echo ":white_check_mark: Previous deployment PR was merged successfully" >> "$GITHUB_STEP_SUMMARY" + else + echo "No previous deployment PRs found (this may be the first automated deployment)" >> "$GITHUB_STEP_SUMMARY" + fi + + echo "" >> "$GITHUB_STEP_SUMMARY" + echo "### Reason for Deploy" >> "$GITHUB_STEP_SUMMARY" + echo "$REASON" >> "$GITHUB_STEP_SUMMARY" + + - name: Slack notification + if: ${{ inputs.NOTIFY_SLACK == true && inputs.DRY_RUN == false && steps.deploy.outputs.pr_url != '' }} + uses: ./actions/.github/actions/slack + with: + MESSAGE: ':rocket: Production deployment PR created for *${{ inputs.SERVICE_NAME }}*\n>*PR:* ${{ steps.deploy.outputs.pr_url }}\n>*Image:* ${{ steps.deploy.outputs.staging_image_tag }}\n>*Reason:* ${{ inputs.REASON }}' + CHANNEL: ${{ inputs.SLACK_CHANNEL }} + env: + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} diff --git a/.github/workflows/cd-gitops.yml b/.github/workflows/cd-gitops.yml index 9c00535f..047a7346 100644 --- a/.github/workflows/cd-gitops.yml +++ b/.github/workflows/cd-gitops.yml @@ -50,6 +50,15 @@ on: required: false description: The branch name to create if CREATE_PR is true. type: string + GIT_SHA: + required: false + type: string + description: Git SHA to update in the stack file. + DRY_RUN: + required: false + type: boolean + default: false + description: Verify changes without pushing. secrets: GITOPS_PAT: required: true @@ -89,5 +98,7 @@ jobs: ORCHESTRATOR: ${{ inputs.ORCHESTRATOR }} BRANCH_NAME: ${{ inputs.BRANCH_NAME }} CREATE_PR: ${{ inputs.CREATE_PR }} - env: - GITOPS_PAT: ${{ secrets.GITOPS_PAT }} \ No newline at end of file + GIT_SHA: ${{ inputs.GIT_SHA }} + DRY_RUN: ${{ inputs.DRY_RUN }} + env: + GITOPS_PAT: ${{ secrets.GITOPS_PAT }} diff --git a/.gitignore b/.gitignore index e5e8094f..3c349054 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,5 @@ ./sonarscanner .DS_Store +node_modules/ +reports/ +coverage/ diff --git a/__tests__/deploy-prod/create-prod-pr.test.js b/__tests__/deploy-prod/create-prod-pr.test.js new file mode 100644 index 00000000..2359a1b4 --- /dev/null +++ b/__tests__/deploy-prod/create-prod-pr.test.js @@ -0,0 +1,314 @@ +const fs = require('fs'); +const os = require('os'); +const path = require('path'); +const { runScript } = require('../helpers/run-script'); +const { createMockDir, addMockCommand, cleanupMockDir } = require('../helpers/mock-commands'); + +const FIXTURES = path.resolve(__dirname, '../fixtures'); + +// Standard set of required args for create-prod-pr.sh +function baseArgs(overrides = {}) { + const defaults = { + '--service-name': 'my-service', + '--branch-name': 'my-service/2026-02-13T10-30-00Z', + '--new-image-tag': '20260213-900-newsha12', + '--new-sha': 'newsha1234567890abcdef1234567890abcdef12', + '--old-image-tag': '20260115-700-oldsha12', + '--old-sha': 'oldsha1234567890abcdef1234567890abcdef12', + '--repo': 'acme-org/gitops-prod', + '--source-repo': 'acme-org/my-service', + '--stack-file': 'infrastructure/my-service.stack.yml', + '--docker-repo': 'acme-org/my-service', + }; + + const merged = { ...defaults, ...overrides }; + const args = []; + for (const [flag, value] of Object.entries(merged)) { + if (value === null) continue; // allow removing args + args.push(flag, value); + } + return args; +} + +function baseEnv() { + return { + DEPLOY_REASON: 'Scheduled weekly release', + PR_LIST: '- [#101](https://github.com/acme-org/my-service/pull/101) - Add feature A', + }; +} + +describe('create-prod-pr.sh', () => { + let mockDir; + + beforeEach(() => { + mockDir = createMockDir(); + }); + + afterEach(() => { + cleanupMockDir(mockDir); + }); + + describe('argument parsing', () => { + it('exits with error on unknown flag', () => { + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + const result = runScript( + 'create-prod-pr.sh', + ['--unknown-flag', 'value'], + { mockDir, env: baseEnv() } + ); + expect(result.exitCode).toBe(1); + expect(result.stdout).toContain('::error::'); + expect(result.stdout).toContain('Unknown option'); + }); + + it('exits with error when required --service-name is missing', () => { + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + const args = baseArgs({ '--service-name': null }); + // Remove the flag entirely + const filtered = []; + for (let i = 0; i < args.length; i += 2) { + if (args[i] !== '--service-name') { + filtered.push(args[i], args[i + 1]); + } + } + const result = runScript('create-prod-pr.sh', filtered, { + mockDir, + env: baseEnv(), + }); + expect(result.exitCode).not.toBe(0); + }); + + it('exits with error when DEPLOY_REASON env var is missing', () => { + addMockCommand(mockDir, 'git', { + script: 'if [[ "$1" == "ls-remote" ]]; then exit 2; fi', + }); + const result = runScript('create-prod-pr.sh', baseArgs(), { + mockDir, + env: { DEPLOY_REASON: '', PR_LIST: 'some list' }, + }); + expect(result.exitCode).not.toBe(0); + }); + }); + + describe('branch existence check', () => { + it('exits 1 when branch already exists on remote', () => { + addMockCommand(mockDir, 'git', { + script: ` +if [[ "$1" == "ls-remote" ]]; then + echo "abc123 refs/heads/my-service/2026-02-13T10-30-00Z" + exit 0 +fi +`, + }); + + const result = runScript('create-prod-pr.sh', baseArgs(), { + mockDir, + env: baseEnv(), + }); + + expect(result.exitCode).toBe(1); + expect(result.stdout).toContain('::error::'); + expect(result.stdout).toContain('already exists'); + }); + }); + + describe('dry-run mode', () => { + beforeEach(() => { + // git ls-remote returns non-zero (branch doesn't exist) + addMockCommand(mockDir, 'git', { + script: 'if [[ "$1" == "ls-remote" ]]; then exit 2; fi', + }); + }); + + it('does not call git checkout, commit, push, or gh pr create', () => { + const callLog = path.join(mockDir, 'calls.log'); + fs.writeFileSync(callLog, ''); + + addMockCommand(mockDir, 'gh', { + script: `echo "gh $*" >> "${callLog}"; exit 0`, + }); + + const result = runScript( + 'create-prod-pr.sh', + [...baseArgs(), '--dry-run'], + { mockDir, env: baseEnv() } + ); + + expect(result.exitCode).toBe(0); + + const calls = fs.readFileSync(callLog, 'utf8'); + expect(calls).not.toContain('gh pr create'); + }); + + it('prints planned actions to stdout', () => { + const result = runScript( + 'create-prod-pr.sh', + [...baseArgs(), '--dry-run'], + { mockDir, env: baseEnv() } + ); + + expect(result.exitCode).toBe(0); + expect(result.stdout).toContain('DRY RUN'); + expect(result.stdout).toContain('Would create branch'); + expect(result.stdout).toContain('Would update file'); + }); + + it('sets pr_url=DRY_RUN_NO_PR_CREATED in GITHUB_OUTPUT', () => { + const result = runScript( + 'create-prod-pr.sh', + [...baseArgs(), '--dry-run'], + { mockDir, env: baseEnv() } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.pr_url).toBe('DRY_RUN_NO_PR_CREATED'); + }); + + it('displays the full PR body in stdout', () => { + const result = runScript( + 'create-prod-pr.sh', + [...baseArgs(), '--dry-run'], + { mockDir, env: baseEnv() } + ); + + expect(result.exitCode).toBe(0); + expect(result.stdout).toContain('Production Deployment: my-service'); + expect(result.stdout).toContain('acme-org/my-service:20260213-900-newsha12'); + expect(result.stdout).toContain('acme-org/my-service:20260115-700-oldsha12'); + expect(result.stdout).toContain('Scheduled weekly release'); + expect(result.stdout).toContain('#101'); + }); + }); + + describe('PR body content', () => { + it('contains all expected sections', () => { + addMockCommand(mockDir, 'git', { + script: 'if [[ "$1" == "ls-remote" ]]; then exit 2; fi', + }); + + const result = runScript( + 'create-prod-pr.sh', + [...baseArgs(), '--dry-run'], + { mockDir, env: baseEnv() } + ); + + expect(result.exitCode).toBe(0); + const output = result.stdout; + + // Image table + expect(output).toContain('**New**'); + expect(output).toContain('**Previous**'); + expect(output).toContain('newsha1234567890abcdef1234567890abcdef12'); + expect(output).toContain('oldsha1234567890abcdef1234567890abcdef12'); + + // Reason + expect(output).toContain('Reason for Deploy'); + expect(output).toContain('Scheduled weekly release'); + + // Comparison link + expect(output).toContain('Full Commit Comparison'); + expect(output).toContain( + 'acme-org/my-service/compare/oldsha1234567890abcdef1234567890abcdef12...newsha1234567890abcdef1234567890abcdef12' + ); + + // PR list + expect(output).toContain('Pull Requests Included'); + + // Checklist + expect(output).toContain('Pre-Merge Checklist'); + expect(output).toContain('Verified the Docker image'); + }); + + it('uses fallback message when PR_LIST is empty', () => { + addMockCommand(mockDir, 'git', { + script: 'if [[ "$1" == "ls-remote" ]]; then exit 2; fi', + }); + + const result = runScript( + 'create-prod-pr.sh', + [...baseArgs(), '--dry-run'], + { mockDir, env: { DEPLOY_REASON: 'Test', PR_LIST: '' } } + ); + + expect(result.exitCode).toBe(0); + expect(result.stdout).toContain('No PRs found between versions'); + }); + }); + + describe('normal mode (non-dry-run)', () => { + it('creates branch, commits, pushes, and creates PR', () => { + const callLog = path.join(mockDir, 'calls.log'); + fs.writeFileSync(callLog, ''); + + addMockCommand(mockDir, 'git', { + script: ` +echo "git $*" >> "${callLog}" +if [[ "$1" == "ls-remote" ]]; then + exit 2 +fi +`, + }); + addMockCommand(mockDir, 'yq', { + script: `echo "yq $*" >> "${callLog}"`, + }); + addMockCommand(mockDir, 'gh', { + script: ` +echo "gh $*" >> "${callLog}" +if [[ "$1" == "pr" && "$2" == "create" ]]; then + echo "https://github.com/acme-org/gitops-prod/pull/99" +fi +`, + }); + + const result = runScript('create-prod-pr.sh', baseArgs(), { + mockDir, + env: baseEnv(), + }); + + expect(result.exitCode).toBe(0); + expect(result.outputs.pr_url).toBe( + 'https://github.com/acme-org/gitops-prod/pull/99' + ); + + const calls = fs.readFileSync(callLog, 'utf8'); + expect(calls).toContain('git checkout -b'); + expect(calls).toContain('git add'); + expect(calls).toContain('git commit'); + expect(calls).toContain('git push origin'); + expect(calls).toContain('gh pr create'); + }); + + it('sets correct PR title format', () => { + const callLog = path.join(mockDir, 'calls.log'); + fs.writeFileSync(callLog, ''); + + addMockCommand(mockDir, 'git', { + script: ` +echo "git $*" >> "${callLog}" +if [[ "$1" == "ls-remote" ]]; then exit 2; fi +`, + }); + addMockCommand(mockDir, 'yq', { + script: `echo "yq $*" >> "${callLog}"`, + }); + addMockCommand(mockDir, 'gh', { + script: ` +echo "gh $*" >> "${callLog}" +if [[ "$1" == "pr" && "$2" == "create" ]]; then + echo "https://github.com/acme-org/gitops-prod/pull/99" +fi +`, + }); + + runScript('create-prod-pr.sh', baseArgs(), { + mockDir, + env: baseEnv(), + }); + + const calls = fs.readFileSync(callLog, 'utf8'); + expect(calls).toContain( + '[my-service] Update image to acme-org/my-service:20260213-900-newsha12' + ); + }); + }); +}); diff --git a/__tests__/deploy-prod/extract-staging-info.test.js b/__tests__/deploy-prod/extract-staging-info.test.js new file mode 100644 index 00000000..e32b8c80 --- /dev/null +++ b/__tests__/deploy-prod/extract-staging-info.test.js @@ -0,0 +1,146 @@ +const path = require('path'); +const { execFileSync } = require('child_process'); +const { runScript } = require('../helpers/run-script'); +const { createMockDir, addMockCommand, cleanupMockDir } = require('../helpers/mock-commands'); + +const FIXTURES = path.resolve(__dirname, '../fixtures'); + +// Detect yq availability for tests that need real YAML parsing +let hasYq = false; +try { + execFileSync('yq', ['--version'], { encoding: 'utf8', stdio: 'pipe' }); + hasYq = true; +} catch (_) {} + +const describeWithYq = hasYq ? describe : describe.skip; + +describe('extract-staging-info.sh', () => { + describe('argument validation', () => { + it('exits with error when no arguments provided', () => { + const result = runScript('extract-staging-info.sh'); + expect(result.exitCode).not.toBe(0); + }); + + it('exits with error when only stack file path provided', () => { + const result = runScript('extract-staging-info.sh', ['/tmp/some-file.yml']); + expect(result.exitCode).not.toBe(0); + }); + + it('exits with error when stack file does not exist', () => { + const result = runScript('extract-staging-info.sh', [ + '/tmp/nonexistent-stack-file.yml', + 'my-service', + ]); + expect(result.exitCode).toBe(1); + expect(result.stdout).toContain('::error::'); + expect(result.stdout).toContain('not found'); + }); + }); + + describeWithYq('yq-based extraction (primary path)', () => { + it('extracts full image, tag, prod tag, and git SHA from standard stack file', () => { + const fixture = path.join(FIXTURES, 'staging-stack.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service']); + + expect(result.exitCode).toBe(0); + expect(result.outputs.full_image).toBe( + 'acme-org/my-service:staging-20260129-765-2cb19ef' + ); + expect(result.outputs.image_tag).toBe('staging-20260129-765-2cb19ef'); + expect(result.outputs.prod_image_tag).toBe('20260129-765-2cb19ef'); + expect(result.outputs.git_sha).toBe( + '2cb19efabc123456789012345678901234567890' + ); + }); + + it('strips staging- prefix to produce prod_image_tag', () => { + const fixture = path.join(FIXTURES, 'staging-stack.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service']); + + expect(result.exitCode).toBe(0); + // prod_image_tag should NOT start with "staging-" + expect(result.outputs.prod_image_tag).not.toMatch(/^staging-/); + // but image_tag should + expect(result.outputs.image_tag).toMatch(/^staging-/); + }); + + it('writes all four outputs to GITHUB_OUTPUT', () => { + const fixture = path.join(FIXTURES, 'staging-stack.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service']); + + expect(result.exitCode).toBe(0); + expect(result.outputs).toHaveProperty('full_image'); + expect(result.outputs).toHaveProperty('image_tag'); + expect(result.outputs).toHaveProperty('prod_image_tag'); + expect(result.outputs).toHaveProperty('git_sha'); + }); + + it('prints human-readable summary to stdout', () => { + const fixture = path.join(FIXTURES, 'staging-stack.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service']); + + expect(result.exitCode).toBe(0); + expect(result.stdout).toContain('Staging image:'); + expect(result.stdout).toContain('Image tag:'); + expect(result.stdout).toContain('Production tag:'); + expect(result.stdout).toContain('GIT_SHA:'); + }); + }); + + describeWithYq('error cases', () => { + it('exits non-zero when image cannot be found for the service', () => { + const fixture = path.join(FIXTURES, 'staging-stack-no-image.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service']); + + // Script fails either via set -euo pipefail (grep no match) or explicit exit 1 + expect(result.exitCode).not.toBe(0); + // Should NOT produce any successful output keys + expect(result.outputs).not.toHaveProperty('prod_image_tag'); + }); + + it('exits non-zero when GIT_SHA is missing from stack file', () => { + const fixture = path.join(FIXTURES, 'staging-stack-no-sha.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service']); + + // Script fails either via set -euo pipefail or explicit exit 1 + expect(result.exitCode).not.toBe(0); + // Should NOT produce a git_sha output + expect(result.outputs).not.toHaveProperty('git_sha'); + }); + }); + + describe('grep fallback path', () => { + let mockDir; + + beforeEach(() => { + mockDir = createMockDir(); + // Mock yq to return empty for image queries but succeed for GIT_SHA + addMockCommand(mockDir, 'yq', { + script: ` +# Return empty for image queries, return SHA for GIT_SHA queries +if echo "$@" | grep -q "GIT_SHA"; then + echo "2cb19efabc123456789012345678901234567890" +else + echo "" +fi +`, + }); + }); + + afterEach(() => { + cleanupMockDir(mockDir); + }); + + it('falls back to grep when yq finds no matching image', () => { + const fixture = path.join(FIXTURES, 'staging-stack.yml'); + const result = runScript('extract-staging-info.sh', [fixture, 'my-service'], { + mockDir, + }); + + expect(result.exitCode).toBe(0); + expect(result.outputs.full_image).toBe( + 'acme-org/my-service:staging-20260129-765-2cb19ef' + ); + }); + }); +}); diff --git a/__tests__/deploy-prod/find-previous-deploy-pr.test.js b/__tests__/deploy-prod/find-previous-deploy-pr.test.js new file mode 100644 index 00000000..05207120 --- /dev/null +++ b/__tests__/deploy-prod/find-previous-deploy-pr.test.js @@ -0,0 +1,209 @@ +const { runScript } = require('../helpers/run-script'); +const { createMockDir, addMockCommand, cleanupMockDir } = require('../helpers/mock-commands'); + +describe('find-previous-deploy-pr.sh', () => { + let mockDir; + + beforeEach(() => { + mockDir = createMockDir(); + }); + + afterEach(() => { + cleanupMockDir(mockDir); + }); + + describe('argument validation', () => { + it('exits with error when no arguments provided', () => { + addMockCommand(mockDir, 'gh', { stdout: '[]', exitCode: 0 }); + const result = runScript('find-previous-deploy-pr.sh', [], { mockDir }); + expect(result.exitCode).not.toBe(0); + }); + + it('exits with error when only repo provided', () => { + addMockCommand(mockDir, 'gh', { stdout: '[]', exitCode: 0 }); + const result = runScript('find-previous-deploy-pr.sh', ['acme-org/gitops-prod'], { + mockDir, + }); + expect(result.exitCode).not.toBe(0); + }); + }); + + describe('no previous PRs found', () => { + it('exits 0 with previous_merged=unknown when gh returns empty array', () => { + addMockCommand(mockDir, 'gh', { stdout: '[]', exitCode: 0 }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service/'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.previous_merged).toBe('unknown'); + }); + + it('exits 0 when no PRs match the branch prefix', () => { + addMockCommand(mockDir, 'gh', { + stdout: JSON.stringify([ + { + number: 10, + headRefName: 'other-service/2026-01-01', + state: 'MERGED', + mergedAt: '2026-01-01T00:00:00Z', + title: 'Deploy other-service', + }, + ]), + }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.previous_merged).toBe('unknown'); + }); + }); + + describe('previous PR was merged', () => { + it('sets previous_merged=true and outputs PR details', () => { + addMockCommand(mockDir, 'gh', { + stdout: JSON.stringify([ + { + number: 42, + headRefName: 'my-service/2026-01-28T10-30-00Z', + state: 'MERGED', + mergedAt: '2026-01-28T12:00:00Z', + title: '[my-service] Update image', + }, + { + number: 40, + headRefName: 'my-service/2026-01-20T08-00-00Z', + state: 'MERGED', + mergedAt: '2026-01-20T10:00:00Z', + title: '[my-service] Update image', + }, + ]), + }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.previous_merged).toBe('true'); + expect(result.outputs.last_pr_number).toBe('42'); + expect(result.outputs.last_pr_state).toBe('MERGED'); + expect(result.outputs.last_pr_branch).toBe('my-service/2026-01-28T10-30-00Z'); + }); + + it('selects the highest-numbered PR matching the prefix', () => { + addMockCommand(mockDir, 'gh', { + stdout: JSON.stringify([ + { + number: 30, + headRefName: 'my-service/2026-01-10', + state: 'MERGED', + mergedAt: '2026-01-10T00:00:00Z', + title: 'Old deploy', + }, + { + number: 50, + headRefName: 'my-service/2026-02-01', + state: 'MERGED', + mergedAt: '2026-02-01T00:00:00Z', + title: 'New deploy', + }, + ]), + }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.last_pr_number).toBe('50'); + }); + }); + + describe('previous PR was not merged', () => { + it('sets previous_merged=false and finds last merged PR', () => { + addMockCommand(mockDir, 'gh', { + stdout: JSON.stringify([ + { + number: 45, + headRefName: 'my-service/2026-02-01', + state: 'OPEN', + mergedAt: null, + title: 'Pending deploy', + }, + { + number: 42, + headRefName: 'my-service/2026-01-28', + state: 'MERGED', + mergedAt: '2026-01-28T12:00:00Z', + title: 'Last merged deploy', + }, + ]), + }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.previous_merged).toBe('false'); + expect(result.outputs.last_pr_number).toBe('45'); + expect(result.outputs.last_pr_state).toBe('OPEN'); + expect(result.outputs.last_merged_pr_number).toBe('42'); + }); + + it('handles CLOSED PR without any merged PRs', () => { + addMockCommand(mockDir, 'gh', { + stdout: JSON.stringify([ + { + number: 45, + headRefName: 'my-service/2026-02-01', + state: 'CLOSED', + mergedAt: null, + title: 'Closed deploy', + }, + ]), + }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.previous_merged).toBe('false'); + expect(result.outputs.last_pr_number).toBe('45'); + expect(result.outputs).not.toHaveProperty('last_merged_pr_number'); + }); + }); + + describe('gh CLI failure', () => { + it('exits 1 when gh pr list fails', () => { + addMockCommand(mockDir, 'gh', { + script: 'echo "HTTP 401: Bad credentials" >&2; exit 1', + }); + + const result = runScript( + 'find-previous-deploy-pr.sh', + ['acme-org/gitops-prod', 'my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(1); + }); + }); +}); diff --git a/__tests__/deploy-prod/get-prs-between-commits.test.js b/__tests__/deploy-prod/get-prs-between-commits.test.js new file mode 100644 index 00000000..9a0e6004 --- /dev/null +++ b/__tests__/deploy-prod/get-prs-between-commits.test.js @@ -0,0 +1,244 @@ +const { runScript } = require('../helpers/run-script'); +const { createMockDir, addMockCommand, cleanupMockDir } = require('../helpers/mock-commands'); + +describe('get-prs-between-commits.sh', () => { + let mockDir; + + beforeEach(() => { + mockDir = createMockDir(); + }); + + afterEach(() => { + cleanupMockDir(mockDir); + }); + + describe('argument validation', () => { + it('exits with error when fewer than 3 arguments provided', () => { + addMockCommand(mockDir, 'gh', { stdout: '', exitCode: 0 }); + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + const result = runScript('get-prs-between-commits.sh', ['abc123'], { mockDir }); + expect(result.exitCode).not.toBe(0); + }); + }); + + describe('GitHub compare API path', () => { + it('extracts PR numbers from merge commits and fetches titles', () => { + const compareResponse = JSON.stringify({ + total_commits: 3, + commits: [ + { + commit: { message: 'Merge pull request #101 from feature-a' }, + parents: [{ sha: 'a' }, { sha: 'b' }], + }, + { + commit: { message: 'fix: a regular commit referencing #999' }, + parents: [{ sha: 'c' }], + }, + { + commit: { message: 'Merge pull request #102 from feature-b' }, + parents: [{ sha: 'd' }, { sha: 'e' }], + }, + ], + }); + + addMockCommand(mockDir, 'gh', { + script: ` +if [[ "$1" == "api" ]]; then + cat <<'EOF' +${compareResponse} +EOF +elif [[ "$1" == "pr" && "$2" == "view" ]]; then + PR_NUM="$3" + if [[ "$PR_NUM" == "101" ]]; then + echo '{"number": 101, "title": "Add feature A"}' + elif [[ "$PR_NUM" == "102" ]]; then + echo '{"number": 102, "title": "Fix bug B"}' + fi +fi +`, + }); + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + + const result = runScript( + 'get-prs-between-commits.sh', + ['abc123', 'def456', 'acme-org/my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.pr_list).toContain('#101'); + expect(result.outputs.pr_list).toContain('Add feature A'); + expect(result.outputs.pr_list).toContain('#102'); + expect(result.outputs.pr_list).toContain('Fix bug B'); + }); + + it('ignores non-merge commits (single parent)', () => { + const compareResponse = JSON.stringify({ + total_commits: 2, + commits: [ + { + commit: { message: 'fix: commit mentioning #999' }, + parents: [{ sha: 'a' }], + }, + { + commit: { message: 'Merge pull request #101 from feature-a' }, + parents: [{ sha: 'b' }, { sha: 'c' }], + }, + ], + }); + + addMockCommand(mockDir, 'gh', { + script: ` +if [[ "$1" == "api" ]]; then + cat <<'EOF' +${compareResponse} +EOF +elif [[ "$1" == "pr" && "$2" == "view" ]]; then + echo '{"number": 101, "title": "Feature A"}' +fi +`, + }); + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + + const result = runScript( + 'get-prs-between-commits.sh', + ['abc123', 'def456', 'acme-org/my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + // PR #999 should NOT appear (single-parent commit) + expect(result.outputs.pr_list).not.toContain('#999'); + // PR #101 should appear (merge commit) + expect(result.outputs.pr_list).toContain('#101'); + }); + }); + + describe('git log fallback', () => { + it('falls back to local git log when gh api fails', () => { + addMockCommand(mockDir, 'gh', { + script: ` +if [[ "$1" == "api" ]]; then + exit 1 +elif [[ "$1" == "pr" && "$2" == "view" ]]; then + echo '{"number": 55, "title": "Some PR"}' +fi +`, + }); + addMockCommand(mockDir, 'git', { + script: ` +if [[ "$1" == "log" ]]; then + echo "abc1234 Merge pull request #55 from branch" +elif [[ "$1" == "rev-list" ]]; then + echo "5" +fi +`, + }); + + const result = runScript( + 'get-prs-between-commits.sh', + ['abc123', 'def456', 'acme-org/my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.pr_list).toContain('#55'); + expect(result.outputs.pr_list).toContain('Some PR'); + }); + }); + + describe('no PRs found', () => { + it('outputs commit count summary when commits exist but no PRs', () => { + const compareResponse = JSON.stringify({ + total_commits: 5, + commits: [ + { + commit: { message: 'chore: update deps' }, + parents: [{ sha: 'a' }], + }, + ], + }); + + addMockCommand(mockDir, 'gh', { + script: ` +if [[ "$1" == "api" ]]; then + cat <<'EOF' +${compareResponse} +EOF +fi +`, + }); + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + + const result = runScript( + 'get-prs-between-commits.sh', + ['abc123', 'def456', 'acme-org/my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.pr_list).toContain('5 commits'); + }); + + it('reports no commits when compare returns 0', () => { + const compareResponse = JSON.stringify({ + total_commits: 0, + commits: [], + }); + + addMockCommand(mockDir, 'gh', { + script: ` +if [[ "$1" == "api" ]]; then + cat <<'EOF' +${compareResponse} +EOF +fi +`, + }); + addMockCommand(mockDir, 'git', { + script: ` +if [[ "$1" == "rev-list" ]]; then + echo "0" +fi +`, + }); + + const result = runScript( + 'get-prs-between-commits.sh', + ['abc123', 'def456', 'acme-org/my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.pr_list).toContain('No commits found'); + }); + }); + + describe('GITHUB_OUTPUT multiline format', () => { + it('uses heredoc delimiter for pr_list output', () => { + addMockCommand(mockDir, 'gh', { + script: ` +if [[ "$1" == "api" ]]; then + echo '{"total_commits": 1, "commits": [{"commit": {"message": "Merge pull request #10 from x"}, "parents": [{"sha":"a"},{"sha":"b"}]}]}' +elif [[ "$1" == "pr" && "$2" == "view" ]]; then + echo '{"number": 10, "title": "Test PR"}' +fi +`, + }); + addMockCommand(mockDir, 'git', { stdout: '', exitCode: 0 }); + + const result = runScript( + 'get-prs-between-commits.sh', + ['abc123', 'def456', 'acme-org/my-service'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + // The output should contain a markdown link + expect(result.outputs.pr_list).toMatch( + /\[#10\]\(https:\/\/github\.com\/acme-org\/my-service\/pull\/10\)/ + ); + expect(result.outputs.pr_list).toContain('Test PR'); + }); + }); +}); diff --git a/__tests__/deploy-prod/verify-docker-image.test.js b/__tests__/deploy-prod/verify-docker-image.test.js new file mode 100644 index 00000000..797ae76b --- /dev/null +++ b/__tests__/deploy-prod/verify-docker-image.test.js @@ -0,0 +1,105 @@ +const { runScript } = require('../helpers/run-script'); +const { createMockDir, addMockCommand, cleanupMockDir } = require('../helpers/mock-commands'); + +describe('verify-docker-image.sh', () => { + let mockDir; + + beforeEach(() => { + mockDir = createMockDir(); + }); + + afterEach(() => { + cleanupMockDir(mockDir); + }); + + describe('argument validation', () => { + it('exits with error when no arguments provided', () => { + const result = runScript('verify-docker-image.sh', [], { mockDir }); + expect(result.exitCode).not.toBe(0); + }); + + it('exits with error when only repository provided', () => { + const result = runScript('verify-docker-image.sh', ['acme-org/my-service'], { + mockDir, + }); + expect(result.exitCode).not.toBe(0); + }); + }); + + describe('docker manifest inspect succeeds', () => { + beforeEach(() => { + addMockCommand(mockDir, 'docker', { + script: 'if [[ "$1" == "manifest" && "$2" == "inspect" ]]; then echo "{}"; exit 0; fi; exit 1', + }); + }); + + it('exits 0 and sets image_exists=true', () => { + const result = runScript( + 'verify-docker-image.sh', + ['acme-org/my-service', '20260129-765-2cb19ef'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.image_exists).toBe('true'); + expect(result.stdout).toContain('verified via manifest inspect'); + }); + }); + + describe('Docker Hub API fallback', () => { + beforeEach(() => { + // docker manifest inspect fails + addMockCommand(mockDir, 'docker', { stdout: '', exitCode: 1 }); + }); + + it('exits 0 when API returns 200', () => { + addMockCommand(mockDir, 'curl', { + // The script uses: curl -s -o /dev/null -w "%{http_code}" + // With our mock, curl just outputs the status code + script: 'echo "200"', + }); + + const result = runScript( + 'verify-docker-image.sh', + ['acme-org/my-service', '20260129-765-2cb19ef'], + { mockDir } + ); + + expect(result.exitCode).toBe(0); + expect(result.outputs.image_exists).toBe('true'); + expect(result.stdout).toContain('verified via Docker Hub API'); + }); + + it('exits 1 when API returns 404', () => { + addMockCommand(mockDir, 'curl', { script: 'echo "404"' }); + + const result = runScript( + 'verify-docker-image.sh', + ['acme-org/my-service', 'nonexistent-tag'], + { mockDir } + ); + + expect(result.exitCode).toBe(1); + expect(result.outputs.image_exists).toBe('false'); + expect(result.stdout).toContain('::error::'); + }); + }); + + describe('both methods fail', () => { + it('exits 1 with error details', () => { + addMockCommand(mockDir, 'docker', { stdout: '', exitCode: 1 }); + addMockCommand(mockDir, 'curl', { script: 'echo "500"' }); + + const result = runScript( + 'verify-docker-image.sh', + ['acme-org/my-service', 'bad-tag'], + { mockDir } + ); + + expect(result.exitCode).toBe(1); + expect(result.outputs.image_exists).toBe('false'); + expect(result.stdout).toContain('::error::'); + expect(result.stdout).toContain('HTTP 500'); + }); + }); +}); diff --git a/__tests__/fixtures/prod-stack.yml b/__tests__/fixtures/prod-stack.yml new file mode 100644 index 00000000..b4011244 --- /dev/null +++ b/__tests__/fixtures/prod-stack.yml @@ -0,0 +1,8 @@ +version: "3.8" +services: + app: + image: acme-org/my-service:20260115-700-oldsha12 + environment: + GIT_SHA: oldsha1234567890abcdef1234567890abcdef12 + deploy: + replicas: 3 diff --git a/__tests__/fixtures/staging-stack-no-image.yml b/__tests__/fixtures/staging-stack-no-image.yml new file mode 100644 index 00000000..fb65588a --- /dev/null +++ b/__tests__/fixtures/staging-stack-no-image.yml @@ -0,0 +1,8 @@ +version: "3.8" +services: + app: + image: unrelated-org/other-service:latest + environment: + GIT_SHA: abc123 + deploy: + replicas: 1 diff --git a/__tests__/fixtures/staging-stack-no-sha.yml b/__tests__/fixtures/staging-stack-no-sha.yml new file mode 100644 index 00000000..ecd31681 --- /dev/null +++ b/__tests__/fixtures/staging-stack-no-sha.yml @@ -0,0 +1,8 @@ +version: "3.8" +services: + app: + image: acme-org/my-service:staging-20260201-780-deadbeef + environment: + NODE_ENV: production + deploy: + replicas: 2 diff --git a/__tests__/fixtures/staging-stack.yml b/__tests__/fixtures/staging-stack.yml new file mode 100644 index 00000000..f6194a4f --- /dev/null +++ b/__tests__/fixtures/staging-stack.yml @@ -0,0 +1,11 @@ +version: "3.8" +services: + app: + image: acme-org/my-service:staging-20260129-765-2cb19ef + environment: + GIT_SHA: 2cb19efabc123456789012345678901234567890 + NODE_ENV: production + deploy: + replicas: 2 + redis: + image: redis:7-alpine diff --git a/__tests__/helpers/github-output.js b/__tests__/helpers/github-output.js new file mode 100644 index 00000000..20161362 --- /dev/null +++ b/__tests__/helpers/github-output.js @@ -0,0 +1,45 @@ +/** + * Parse a GITHUB_OUTPUT file into a key-value map. + * + * Supports two formats: + * - Simple: key=value + * - Multiline: key< 0) { + const key = line.substring(0, eqIndex); + const value = line.substring(eqIndex + 1); + outputs[key] = value; + } + i++; + } + + return outputs; +} + +module.exports = { parseGitHubOutput }; diff --git a/__tests__/helpers/mock-commands.js b/__tests__/helpers/mock-commands.js new file mode 100644 index 00000000..cc014c57 --- /dev/null +++ b/__tests__/helpers/mock-commands.js @@ -0,0 +1,45 @@ +const fs = require('fs'); +const os = require('os'); +const path = require('path'); + +/** + * Create a temporary directory for mock command stubs. + */ +function createMockDir() { + return fs.mkdtempSync(path.join(os.tmpdir(), 'mock-cmds-')); +} + +/** + * Add a mock command stub to a mock directory. + * + * @param {string} mockDir - Directory created by createMockDir() + * @param {string} name - Command name (e.g., 'yq', 'gh', 'docker') + * @param {object} behavior - One of: + * { stdout: string, exitCode?: number } - static response + * { script: string } - raw bash script body + */ +function addMockCommand(mockDir, name, behavior) { + const scriptPath = path.join(mockDir, name); + let body; + + if (behavior.script) { + body = `#!/bin/bash\n${behavior.script}`; + } else { + const exit = behavior.exitCode || 0; + const out = behavior.stdout || ''; + // Use a heredoc to avoid quoting issues with special characters + body = `#!/bin/bash\ncat <<'MOCK_STDOUT_EOF'\n${out}\nMOCK_STDOUT_EOF\nexit ${exit}`; + } + + fs.writeFileSync(scriptPath, body, { mode: 0o755 }); + return scriptPath; +} + +/** + * Remove a mock directory and all its contents. + */ +function cleanupMockDir(mockDir) { + fs.rmSync(mockDir, { recursive: true, force: true }); +} + +module.exports = { createMockDir, addMockCommand, cleanupMockDir }; diff --git a/__tests__/helpers/run-script.js b/__tests__/helpers/run-script.js new file mode 100644 index 00000000..d9f62dd6 --- /dev/null +++ b/__tests__/helpers/run-script.js @@ -0,0 +1,80 @@ +const { execFileSync } = require('child_process'); +const fs = require('fs'); +const os = require('os'); +const path = require('path'); +const { parseGitHubOutput } = require('./github-output'); + +const SCRIPTS_DIR = path.resolve( + __dirname, + '../../.github/actions/deploy-prod/scripts' +); + +/** + * Run a deploy-prod shell script and capture its results. + * + * @param {string} scriptName - Filename in deploy-prod/scripts/ (e.g., 'extract-staging-info.sh') + * @param {string[]} args - Positional arguments + * @param {object} options + * @param {object} options.env - Extra environment variables + * @param {string} options.mockDir - Directory with mock command stubs (prepended to PATH) + * @param {string} options.cwd - Working directory for the script + * + * @returns {{ stdout: string, stderr: string, exitCode: number, outputs: object }} + */ +function runScript(scriptName, args = [], options = {}) { + const scriptPath = path.join(SCRIPTS_DIR, scriptName); + const outputFile = path.join( + os.tmpdir(), + `gh-output-${Date.now()}-${Math.random().toString(36).slice(2)}` + ); + fs.writeFileSync(outputFile, ''); + + const env = { + ...process.env, + GITHUB_OUTPUT: outputFile, + // Strip host tokens that could leak into tests + GITHUB_TOKEN: '', + GH_TOKEN: '', + ...options.env, + }; + + if (options.mockDir) { + env.PATH = `${options.mockDir}:${env.PATH}`; + } + + let stdout = ''; + let stderr = ''; + let exitCode = 0; + + try { + stdout = execFileSync('bash', [scriptPath, ...args], { + env, + cwd: options.cwd || os.tmpdir(), + encoding: 'utf8', + timeout: 10000, + stdio: ['pipe', 'pipe', 'pipe'], + }); + } catch (err) { + stdout = err.stdout || ''; + stderr = err.stderr || ''; + exitCode = err.status || 1; + } + + let outputs = {}; + try { + const outputContent = fs.readFileSync(outputFile, 'utf8'); + outputs = parseGitHubOutput(outputContent); + } catch (_) { + // output file may have been deleted by script + } + + try { + fs.unlinkSync(outputFile); + } catch (_) { + // already cleaned up + } + + return { stdout, stderr, exitCode, outputs }; +} + +module.exports = { runScript, SCRIPTS_DIR }; diff --git a/actions-md/Deploy-prod.md b/actions-md/Deploy-prod.md new file mode 100644 index 00000000..51f7c3bc --- /dev/null +++ b/actions-md/Deploy-prod.md @@ -0,0 +1,119 @@ + _ ____ _____ ___ ___ _ _ ____ ___ ____ ____ + / \ / ___| |_ _| |_ _| / _ \ | \ | | | _ \ / _ \ / ___| / ___| + / _ \ | | | | | | | | | | | \| | _____ | | | | | | | | | | \___ \ + / ___ \ | |___ | | | | | |_| | | |\ | |_____| | |_| | | |_| | | |___ ___) | + /_/ \_\ \____| |_| |___| \___/ |_| \_| |____/ \___/ \____| |____/ + +## Description + +Promotes a staging image to production by creating a PR in a production GitOps repository. Extracts the current staging image, verifies it exists on Docker Hub, collects a changelog of PRs between the old and new versions, and creates a deployment PR with full context. + +Consists of a reusable workflow (`cd-deploy-prod.yml`) and a composite action (`deploy-prod`). + +## Workflow Inputs + +| parameter | description | required | default | +| --- | --- | --- | --- | +| SERVICE_NAME | Service name used for image naming, stack file paths, and PR titles | `true` | | +| REASON | Reason for this production deployment | `true` | | +| DRY_RUN | Verify everything but do not create tag or PR | `false` | `false` | +| BRANCH_PREFIX | Branch prefix for deployment PRs in the prod GitOps repo | `false` | `SERVICE_NAME` | +| GITOPS_STAGING_REPO | GitOps staging repository to read current staging image from | `true` | | +| GITOPS_PROD_REPO | GitOps production repository to create deployment PR in | `true` | | +| STACK_FILE_PATH | Path to stack file in GitOps repos | `false` | `infrastructure/${SERVICE_NAME}.stack.yml` | +| DOCKER_REPOSITORY | Docker repository for image verification | `false` | `signalwire/${SERVICE_NAME}` | +| SOURCE_REPO | Source repository for commit comparison links | `false` | `signalwire/${SERVICE_NAME}` | +| BASE_BRANCH | Base branch in the prod GitOps repo | `false` | `main` | +| RUNNER | Runner to use for the deployment job | `false` | `ubuntu-latest` | +| ACTIONS_REF | Ref of signalwire/actions-template to use | `false` | `main` | +| NOTIFY_SLACK | Send Slack notification on deployment PR creation | `false` | `false` | +| SLACK_CHANNEL | Slack channel for deployment notifications | `false` | | + +## Secrets + +| secret | description | required | +| --- | --- | --- | +| GITOPS_PAT_STAGING | PAT with read access to the staging GitOps repo | `true` | +| GITOPS_PAT_PROD | PAT with read/write access to the production GitOps repo | `true` | +| DOCKERHUB_USERNAME | Docker Hub username for image verification | `true` | +| DOCKERHUB_TOKEN | Docker Hub token for image verification | `true` | +| SLACK_WEBHOOK_URL | Slack webhook URL for deployment notifications | `false` | + +## Outputs + +| output | description | +| --- | --- | +| NEW_TAG | The timestamp tag created on the source repo | +| PR_URL | URL of the deployment PR created in the prod GitOps repo | +| STAGING_IMAGE_TAG | The image tag extracted from staging | +| PREVIOUS_MERGED | Whether the previous deployment PR for this service was merged | + +## Runs + +This workflow is a `workflow_call` reusable workflow backed by a `composite` action. + +## Usage + +In the consuming repository, create a workflow that calls `cd-deploy-prod.yml`: + +```yaml +name: Deploy to Production + +on: + workflow_dispatch: + inputs: + reason: + description: 'Reason for this production deployment' + required: true + type: string + dry_run: + description: 'Dry run mode' + required: false + default: false + type: boolean + +jobs: + deploy: + uses: signalwire/actions-template/.github/workflows/cd-deploy-prod.yml@main + with: + SERVICE_NAME: 'my-service' + REASON: ${{ inputs.reason }} + DRY_RUN: ${{ inputs.dry_run }} + GITOPS_STAGING_REPO: 'org/gitops-staging' + GITOPS_PROD_REPO: 'org/gitops-prod' + secrets: + GITOPS_PAT_STAGING: ${{ secrets.GITOPS_PAT_STAGING }} + GITOPS_PAT_PROD: ${{ secrets.GITOPS_PAT_PROD }} + DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} + DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }} +``` + +### With custom branch prefix and Slack notifications + +```yaml +jobs: + deploy: + uses: signalwire/actions-template/.github/workflows/cd-deploy-prod.yml@main + with: + SERVICE_NAME: 'my-service' + REASON: ${{ inputs.reason }} + DRY_RUN: ${{ inputs.dry_run }} + BRANCH_PREFIX: 'my-svc' + GITOPS_STAGING_REPO: 'org/gitops-staging' + GITOPS_PROD_REPO: 'org/gitops-prod' + NOTIFY_SLACK: true + SLACK_CHANNEL: '#deployments' + secrets: + GITOPS_PAT_STAGING: ${{ secrets.GITOPS_PAT_STAGING }} + GITOPS_PAT_PROD: ${{ secrets.GITOPS_PAT_PROD }} + DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} + DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }} + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} +``` + +## Assumptions + +- Stack files are in docker-compose/stack format with `services..image` and `GIT_SHA` in environment sections. +- Staging image tags may have a `staging-` prefix which is stripped for production. +- Tag format is ISO 8601 timestamps: `YYYY-MM-DDTHH-MM-SSZ`. +- The source repository checkout must have full git history (`fetch-depth: 0`). diff --git a/jest.config.js b/jest.config.js index 79038a1d..08990090 100644 --- a/jest.config.js +++ b/jest.config.js @@ -8,5 +8,6 @@ module.exports = { outputDirectory: 'reports', outputName: 'jest-junit.xml', } ] - ] + ], + testTimeout: 15000, }; \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 00000000..558382ff --- /dev/null +++ b/package-lock.json @@ -0,0 +1,3695 @@ +{ + "name": "actions-template-tests", + "version": "0.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "actions-template-tests", + "version": "0.0.0", + "devDependencies": { + "jest": "^29.7.0", + "jest-junit": "^16.0.0" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.29.0", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.29.0.tgz", + "integrity": "sha512-9NhCeYjq9+3uxgdtp20LSiJXJvN0FeCtNGpJxuMFZ1Kv3cWUNb6DOhJwUvcVCzKGR66cw4njwM6hrJLqgOwbcw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.29.0", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.29.0.tgz", + "integrity": "sha512-T1NCJqT/j9+cn8fvkt7jtwbLBfLC/1y1c7NtCeXFRgzGTsafi68MRv8yzkYSapBnFA6L3U2VSc02ciDzoAJhJg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.29.0", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.29.0.tgz", + "integrity": "sha512-CGOfOJqWjg2qW/Mb6zNsDm+u5vFQ8DxXfbM09z69p5Z6+mE1ikP2jUXw+j42Pf1XTYED2Rni5f95npYeuwMDQA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.29.0", + "@babel/generator": "^7.29.0", + "@babel/helper-compilation-targets": "^7.28.6", + "@babel/helper-module-transforms": "^7.28.6", + "@babel/helpers": "^7.28.6", + "@babel/parser": "^7.29.0", + "@babel/template": "^7.28.6", + "@babel/traverse": "^7.29.0", + "@babel/types": "^7.29.0", + "@jridgewell/remapping": "^2.3.5", + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/generator": { + "version": "7.29.1", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.29.1.tgz", + "integrity": "sha512-qsaF+9Qcm2Qv8SRIMMscAvG4O3lJ0F1GuMo5HR/Bp02LopNgnZBC/EkbevHFeGs4ls/oPz9v+Bsmzbkbe+0dUw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.29.0", + "@babel/types": "^7.29.0", + "@jridgewell/gen-mapping": "^0.3.12", + "@jridgewell/trace-mapping": "^0.3.28", + "jsesc": "^3.0.2" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.28.6.tgz", + "integrity": "sha512-JYtls3hqi15fcx5GaSNL7SCTJ2MNmjrkHXg4FSpOA/grxK8KwyZ5bubHsCq8FXCkua6xhuaaBit+3b7+VZRfcA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/compat-data": "^7.28.6", + "@babel/helper-validator-option": "^7.27.1", + "browserslist": "^4.24.0", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-globals": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@babel/helper-globals/-/helper-globals-7.28.0.tgz", + "integrity": "sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.28.6.tgz", + "integrity": "sha512-l5XkZK7r7wa9LucGw9LwZyyCUscb4x37JWTPz7swwFE/0FMQAGpiWUZn8u9DzkSBWEcK25jmvubfpw2dnAMdbw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.28.6", + "@babel/types": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.28.6.tgz", + "integrity": "sha512-67oXFAYr2cDLDVGLXTEABjdBJZ6drElUSI7WKp70NrpyISso3plG9SAGEF6y7zbha/wOzUByWWTJvEDVNIUGcA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-imports": "^7.28.6", + "@babel/helper-validator-identifier": "^7.28.5", + "@babel/traverse": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.28.6.tgz", + "integrity": "sha512-S9gzZ/bz83GRysI7gAD4wPT/AI3uCnY+9xn+Mx/KPs2JwHJIz1W8PZkg2cqyt3RNOBM8ejcXhV6y8Og7ly/Dug==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz", + "integrity": "sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz", + "integrity": "sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.28.6.tgz", + "integrity": "sha512-xOBvwq86HHdB7WUDTfKfT/Vuxh7gElQ+Sfti2Cy6yIWNW05P8iUslOVcZ4/sKbE+/jQaukQAdz/gf3724kYdqw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/template": "^7.28.6", + "@babel/types": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.29.0", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.29.0.tgz", + "integrity": "sha512-IyDgFV5GeDUVX4YdF/3CPULtVGSXXMLh1xVIgdCgxApktqnQV0r7/8Nqthg+8YLGaAtdyIlo2qIdZrbCv4+7ww==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.29.0" + }, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-bigint": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz", + "integrity": "sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", + "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-attributes": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.28.6.tgz", + "integrity": "sha512-jiLC0ma9XkQT3TKJ9uYvlakm66Pamywo+qwL+oL8HJOvc6TWdZXVfhqJr8CCzbSGUAbDOzlGHJC1U+vRfLQDvw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-meta": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", + "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-jsx": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.28.6.tgz", + "integrity": "sha512-wgEmr06G6sIpqr8YDwA2dSRTE3bJ+V0IfpzfSY3Lfgd7YWOaAdlykvJi13ZKBt8cZHfgH1IXN+CL656W3uUa4w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", + "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-typescript": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.28.6.tgz", + "integrity": "sha512-+nDNmQye7nlnuuHDboPbGm00Vqg3oO8niRRL27/4LYHUsHYh0zJ1xWOz0uRwNFmM1Avzk8wZbc6rdiYhomzv/A==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/template": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.28.6.tgz", + "integrity": "sha512-YA6Ma2KsCdGb+WC6UpBVFJGXL58MDA6oyONbjyF/+5sBgxY/dwkhLogbMT2GXXyU84/IhRw/2D1Os1B/giz+BQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.28.6", + "@babel/parser": "^7.28.6", + "@babel/types": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.29.0", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.29.0.tgz", + "integrity": "sha512-4HPiQr0X7+waHfyXPZpWPfWL/J7dcN1mx9gL6WdQVMbPnF3+ZhSMs8tCxN7oHddJE9fhNE7+lxdnlyemKfJRuA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.29.0", + "@babel/generator": "^7.29.0", + "@babel/helper-globals": "^7.28.0", + "@babel/parser": "^7.29.0", + "@babel/template": "^7.28.6", + "@babel/types": "^7.29.0", + "debug": "^4.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/types": { + "version": "7.29.0", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.29.0.tgz", + "integrity": "sha512-LwdZHpScM4Qz8Xw2iKSzS+cfglZzJGvofQICy7W7v4caru4EaAmyUuO6BGrbyQ2mYV11W0U8j5mBhd14dd3B0A==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-string-parser": "^7.27.1", + "@babel/helper-validator-identifier": "^7.28.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@bcoe/v8-coverage": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz", + "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@istanbuljs/load-nyc-config": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz", + "integrity": "sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==", + "dev": true, + "license": "ISC", + "dependencies": { + "camelcase": "^5.3.1", + "find-up": "^4.1.0", + "get-package-type": "^0.1.0", + "js-yaml": "^3.13.1", + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@istanbuljs/schema": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", + "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/console": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/console/-/console-29.7.0.tgz", + "integrity": "sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/core": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.7.0.tgz", + "integrity": "sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/reporters": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "jest-changed-files": "^29.7.0", + "jest-config": "^29.7.0", + "jest-haste-map": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-resolve-dependencies": "^29.7.0", + "jest-runner": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "jest-watcher": "^29.7.0", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/@jest/environment": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.7.0.tgz", + "integrity": "sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/fake-timers": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-mock": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "expect": "^29.7.0", + "jest-snapshot": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.7.0.tgz", + "integrity": "sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==", + "dev": true, + "license": "MIT", + "dependencies": { + "jest-get-type": "^29.6.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.7.0.tgz", + "integrity": "sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "@sinonjs/fake-timers": "^10.0.2", + "@types/node": "*", + "jest-message-util": "^29.7.0", + "jest-mock": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/globals": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/globals/-/globals-29.7.0.tgz", + "integrity": "sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/expect": "^29.7.0", + "@jest/types": "^29.6.3", + "jest-mock": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/reporters": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.7.0.tgz", + "integrity": "sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@bcoe/v8-coverage": "^0.2.3", + "@jest/console": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@jridgewell/trace-mapping": "^0.3.18", + "@types/node": "*", + "chalk": "^4.0.0", + "collect-v8-coverage": "^1.0.0", + "exit": "^0.1.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "istanbul-lib-coverage": "^3.0.0", + "istanbul-lib-instrument": "^6.0.0", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^4.0.0", + "istanbul-reports": "^3.1.3", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "jest-worker": "^29.7.0", + "slash": "^3.0.0", + "string-length": "^4.0.1", + "strip-ansi": "^6.0.0", + "v8-to-istanbul": "^9.0.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@sinclair/typebox": "^0.27.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/source-map": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-29.6.3.tgz", + "integrity": "sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.18", + "callsites": "^3.0.0", + "graceful-fs": "^4.2.9" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/test-result": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-29.7.0.tgz", + "integrity": "sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "collect-v8-coverage": "^1.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/test-sequencer": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz", + "integrity": "sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/test-result": "^29.7.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/transform": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-29.7.0.tgz", + "integrity": "sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.11.6", + "@jest/types": "^29.6.3", + "@jridgewell/trace-mapping": "^0.3.18", + "babel-plugin-istanbul": "^6.1.1", + "chalk": "^4.0.0", + "convert-source-map": "^2.0.0", + "fast-json-stable-stringify": "^2.1.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-util": "^29.7.0", + "micromatch": "^4.0.4", + "pirates": "^4.0.4", + "slash": "^3.0.0", + "write-file-atomic": "^4.0.2" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.13", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", + "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/sourcemap-codec": "^1.5.0", + "@jridgewell/trace-mapping": "^0.3.24" + } + }, + "node_modules/@jridgewell/remapping": { + "version": "2.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz", + "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "dev": true, + "license": "MIT" + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@sinclair/typebox": { + "version": "0.27.10", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.10.tgz", + "integrity": "sha512-MTBk/3jGLNB2tVxv6uLlFh1iu64iYOQ2PbdOSK3NW8JZsmlaOh2q6sdtKowBhfw8QFLmYNzTW4/oK4uATIi6ZA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "type-detect": "4.0.8" + } + }, + "node_modules/@sinonjs/fake-timers": { + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz", + "integrity": "sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@sinonjs/commons": "^3.0.0" + } + }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.27.0", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.27.0.tgz", + "integrity": "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.28.0.tgz", + "integrity": "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.28.2" + } + }, + "node_modules/@types/graceful-fs": { + "version": "4.1.9", + "resolved": "https://registry.npmjs.org/@types/graceful-fs/-/graceful-fs-4.1.9.tgz", + "integrity": "sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/istanbul-lib-coverage": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/istanbul-lib-report": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", + "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/istanbul-lib-coverage": "*" + } + }, + "node_modules/@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/istanbul-lib-report": "*" + } + }, + "node_modules/@types/node": { + "version": "25.2.3", + "resolved": "https://registry.npmjs.org/@types/node/-/node-25.2.3.tgz", + "integrity": "sha512-m0jEgYlYz+mDJZ2+F4v8D1AyQb+QzsNqRuI7xg1VQX/KlKS0qT9r1Mo16yo5F/MtifXFgaofIFsdFMox2SxIbQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~7.16.0" + } + }, + "node_modules/@types/stack-utils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/yargs": { + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/yargs-parser": "*" + } + }, + "node_modules/@types/yargs-parser": { + "version": "21.0.3", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", + "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "license": "ISC", + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "license": "MIT", + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/babel-jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.7.0.tgz", + "integrity": "sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/transform": "^29.7.0", + "@types/babel__core": "^7.1.14", + "babel-plugin-istanbul": "^6.1.1", + "babel-preset-jest": "^29.6.3", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.8.0" + } + }, + "node_modules/babel-plugin-istanbul": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", + "integrity": "sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-instrument": "^5.0.4", + "test-exclude": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-istanbul/node_modules/istanbul-lib-instrument": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz", + "integrity": "sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@babel/core": "^7.12.3", + "@babel/parser": "^7.14.7", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-jest-hoist": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz", + "integrity": "sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/template": "^7.3.3", + "@babel/types": "^7.3.3", + "@types/babel__core": "^7.1.14", + "@types/babel__traverse": "^7.0.6" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/babel-preset-current-node-syntax": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.2.0.tgz", + "integrity": "sha512-E/VlAEzRrsLEb2+dv8yp3bo4scof3l9nR4lrld+Iy5NyVqgVYUJnDAmunkhPMisRI32Qc4iRiz425d8vM++2fg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-import-attributes": "^7.24.7", + "@babel/plugin-syntax-import-meta": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5" + }, + "peerDependencies": { + "@babel/core": "^7.0.0 || ^8.0.0-0" + } + }, + "node_modules/babel-preset-jest": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz", + "integrity": "sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA==", + "dev": true, + "license": "MIT", + "dependencies": { + "babel-plugin-jest-hoist": "^29.6.3", + "babel-preset-current-node-syntax": "^1.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true, + "license": "MIT" + }, + "node_modules/baseline-browser-mapping": { + "version": "2.9.19", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.19.tgz", + "integrity": "sha512-ipDqC8FrAl/76p2SSWKSI+H9tFwm7vYqXQrItCuiVPt26Km0jS+NzSsBWAaBusvSbQcfJG+JitdMm+wZAgTYqg==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "baseline-browser-mapping": "dist/cli.js" + } + }, + "node_modules/brace-expansion": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz", + "integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "license": "MIT", + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/browserslist": { + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.1.tgz", + "integrity": "sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "baseline-browser-mapping": "^2.9.0", + "caniuse-lite": "^1.0.30001759", + "electron-to-chromium": "^1.5.263", + "node-releases": "^2.0.27", + "update-browserslist-db": "^1.2.0" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/bser": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", + "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "node-int64": "^0.4.0" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001769", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001769.tgz", + "integrity": "sha512-BCfFL1sHijQlBGWBMuJyhZUhzo7wer5sVj9hqekB/7xn0Ypy+pER/edCYQm4exbXj4WiySGp40P8UuTh6w1srg==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "CC-BY-4.0" + }, + "node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/char-regex": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", + "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + } + }, + "node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/cjs-module-lexer": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-1.4.3.tgz", + "integrity": "sha512-9z8TZaGM1pfswYeXrUpzPrkx8UnWYdhJclsiYMm6x/w5+nN+8Tf/LnAgfLGQCm59qAOxU8WwHEq2vNwF6i4j+Q==", + "dev": true, + "license": "MIT" + }, + "node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dev": true, + "license": "ISC", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==", + "dev": true, + "license": "MIT", + "engines": { + "iojs": ">= 1.0.0", + "node": ">= 0.12.0" + } + }, + "node_modules/collect-v8-coverage": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/collect-v8-coverage/-/collect-v8-coverage-1.0.3.tgz", + "integrity": "sha512-1L5aqIkwPfiodaMgQunkF1zRhNqifHBmtbbbxcr6yVxxBnliw4TDOW6NxpO8DJLgJ16OT+Y4ztZqP6p/FtXnAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", + "dev": true, + "license": "MIT" + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true, + "license": "MIT" + }, + "node_modules/create-jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/create-jest/-/create-jest-29.7.0.tgz", + "integrity": "sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "jest-config": "^29.7.0", + "jest-util": "^29.7.0", + "prompts": "^2.0.1" + }, + "bin": { + "create-jest": "bin/create-jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/cross-spawn": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/debug": { + "version": "4.4.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", + "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/dedent": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/dedent/-/dedent-1.7.1.tgz", + "integrity": "sha512-9JmrhGZpOlEgOLdQgSm0zxFaYoQon408V1v49aqTWuXENVlnCuY9JBZcXZiCsZQWDjTm5Qf/nIvAy77mXDAjEg==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "babel-plugin-macros": "^3.1.0" + }, + "peerDependenciesMeta": { + "babel-plugin-macros": { + "optional": true + } + } + }, + "node_modules/deepmerge": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", + "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/detect-newline": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", + "integrity": "sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/diff-sequences": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-29.6.3.tgz", + "integrity": "sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.5.286", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.286.tgz", + "integrity": "sha512-9tfDXhJ4RKFNerfjdCcZfufu49vg620741MNs26a9+bhLThdB+plgMeou98CAaHu/WATj2iHOOHTp1hWtABj2A==", + "dev": true, + "license": "ISC" + }, + "node_modules/emittery": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/emittery/-/emittery-0.13.1.tgz", + "integrity": "sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sindresorhus/emittery?sponsor=1" + } + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true, + "license": "MIT" + }, + "node_modules/error-ex": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.4.tgz", + "integrity": "sha512-sqQamAnR14VgCr1A618A3sGrygcpK+HEbenA/HiEAkkUwcZIIB/tgWqHFxWgOyDh4nB4JCRimh79dR5Ywc9MDQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-string-regexp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", + "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "license": "BSD-2-Clause", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/exit": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/exit/-/exit-0.1.2.tgz", + "integrity": "sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ==", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/expect-utils": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true, + "license": "MIT" + }, + "node_modules/fb-watchman": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", + "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "bser": "2.1.1" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "license": "MIT", + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "license": "MIT", + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", + "dev": true, + "license": "ISC" + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", + "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true, + "license": "ISC", + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "deprecated": "Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me", + "dev": true, + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/html-escaper": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", + "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", + "dev": true, + "license": "MIT" + }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/import-local": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.2.0.tgz", + "integrity": "sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==", + "dev": true, + "license": "MIT", + "dependencies": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.19" + } + }, + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "deprecated": "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.", + "dev": true, + "license": "ISC", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", + "dev": true, + "license": "MIT" + }, + "node_modules/is-core-module": { + "version": "2.16.1", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.1.tgz", + "integrity": "sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==", + "dev": true, + "license": "MIT", + "dependencies": { + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-generator-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-2.1.0.tgz", + "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true, + "license": "ISC" + }, + "node_modules/istanbul-lib-coverage": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz", + "integrity": "sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-instrument/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-report": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz", + "integrity": "sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^4.0.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-source-maps": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", + "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-reports": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.2.0.tgz", + "integrity": "sha512-HGYWWS/ehqTV3xN10i23tkPkpH46MLCIMFNCaaKNavAXTF1RkqxawEPtnjnGZ6XKSInBKkiOA5BKS+aZiY3AvA==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest/-/jest-29.7.0.tgz", + "integrity": "sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/core": "^29.7.0", + "@jest/types": "^29.6.3", + "import-local": "^3.0.2", + "jest-cli": "^29.7.0" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/jest-changed-files": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-29.7.0.tgz", + "integrity": "sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w==", + "dev": true, + "license": "MIT", + "dependencies": { + "execa": "^5.0.0", + "jest-util": "^29.7.0", + "p-limit": "^3.1.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-circus": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-circus/-/jest-circus-29.7.0.tgz", + "integrity": "sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/expect": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "co": "^4.6.0", + "dedent": "^1.0.0", + "is-generator-fn": "^2.0.0", + "jest-each": "^29.7.0", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "p-limit": "^3.1.0", + "pretty-format": "^29.7.0", + "pure-rand": "^6.0.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-cli": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.7.0.tgz", + "integrity": "sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/core": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "create-jest": "^29.7.0", + "exit": "^0.1.2", + "import-local": "^3.0.2", + "jest-config": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "yargs": "^17.3.1" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/jest-config": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.7.0.tgz", + "integrity": "sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.11.6", + "@jest/test-sequencer": "^29.7.0", + "@jest/types": "^29.6.3", + "babel-jest": "^29.7.0", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "deepmerge": "^4.2.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "jest-circus": "^29.7.0", + "jest-environment-node": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-runner": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "micromatch": "^4.0.4", + "parse-json": "^5.2.0", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@types/node": "*", + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "ts-node": { + "optional": true + } + } + }, + "node_modules/jest-diff": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.7.0.tgz", + "integrity": "sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.0.0", + "diff-sequences": "^29.6.3", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-docblock": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.7.0.tgz", + "integrity": "sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g==", + "dev": true, + "license": "MIT", + "dependencies": { + "detect-newline": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-each": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.7.0.tgz", + "integrity": "sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "jest-util": "^29.7.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-environment-node": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-29.7.0.tgz", + "integrity": "sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/fake-timers": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-mock": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-haste-map": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-29.7.0.tgz", + "integrity": "sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "@types/graceful-fs": "^4.1.3", + "@types/node": "*", + "anymatch": "^3.0.3", + "fb-watchman": "^2.0.0", + "graceful-fs": "^4.2.9", + "jest-regex-util": "^29.6.3", + "jest-util": "^29.7.0", + "jest-worker": "^29.7.0", + "micromatch": "^4.0.4", + "walker": "^1.0.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "optionalDependencies": { + "fsevents": "^2.3.2" + } + }, + "node_modules/jest-junit": { + "version": "16.0.0", + "resolved": "https://registry.npmjs.org/jest-junit/-/jest-junit-16.0.0.tgz", + "integrity": "sha512-A94mmw6NfJab4Fg/BlvVOUXzXgF0XIH6EmTgJ5NDPp4xoKq0Kr7sErb+4Xs9nZvu58pJojz5RFGpqnZYJTrRfQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "mkdirp": "^1.0.4", + "strip-ansi": "^6.0.1", + "uuid": "^8.3.2", + "xml": "^1.0.1" + }, + "engines": { + "node": ">=10.12.0" + } + }, + "node_modules/jest-leak-detector": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz", + "integrity": "sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw==", + "dev": true, + "license": "MIT", + "dependencies": { + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-matcher-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz", + "integrity": "sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.0.0", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-message-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", + "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.12.13", + "@jest/types": "^29.6.3", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-mock": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.7.0.tgz", + "integrity": "sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-pnp-resolver": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz", + "integrity": "sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + }, + "peerDependencies": { + "jest-resolve": "*" + }, + "peerDependenciesMeta": { + "jest-resolve": { + "optional": true + } + } + }, + "node_modules/jest-regex-util": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-29.6.3.tgz", + "integrity": "sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-29.7.0.tgz", + "integrity": "sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA==", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-pnp-resolver": "^1.2.2", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "resolve": "^1.20.0", + "resolve.exports": "^2.0.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve-dependencies": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz", + "integrity": "sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA==", + "dev": true, + "license": "MIT", + "dependencies": { + "jest-regex-util": "^29.6.3", + "jest-snapshot": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-runner": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.7.0.tgz", + "integrity": "sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/environment": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "graceful-fs": "^4.2.9", + "jest-docblock": "^29.7.0", + "jest-environment-node": "^29.7.0", + "jest-haste-map": "^29.7.0", + "jest-leak-detector": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-resolve": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-util": "^29.7.0", + "jest-watcher": "^29.7.0", + "jest-worker": "^29.7.0", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-runtime": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.7.0.tgz", + "integrity": "sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/fake-timers": "^29.7.0", + "@jest/globals": "^29.7.0", + "@jest/source-map": "^29.6.3", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "cjs-module-lexer": "^1.0.0", + "collect-v8-coverage": "^1.0.0", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-mock": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "slash": "^3.0.0", + "strip-bom": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-snapshot": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.7.0.tgz", + "integrity": "sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.11.6", + "@babel/generator": "^7.7.2", + "@babel/plugin-syntax-jsx": "^7.7.2", + "@babel/plugin-syntax-typescript": "^7.7.2", + "@babel/types": "^7.3.3", + "@jest/expect-utils": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "babel-preset-current-node-syntax": "^1.0.0", + "chalk": "^4.0.0", + "expect": "^29.7.0", + "graceful-fs": "^4.2.9", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "natural-compare": "^1.4.0", + "pretty-format": "^29.7.0", + "semver": "^7.5.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/jest-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", + "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-validate": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", + "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^29.6.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "leven": "^3.1.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/jest-watcher": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.7.0.tgz", + "integrity": "sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "jest-util": "^29.7.0", + "string-length": "^4.0.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-worker": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", + "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "jest-util": "^29.7.0", + "merge-stream": "^2.0.0", + "supports-color": "^8.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-worker/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/js-yaml": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", + "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "dev": true, + "license": "MIT", + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/jsesc": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", + "dev": true, + "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "dev": true, + "license": "MIT" + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "dev": true, + "license": "MIT", + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/kleur": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", + "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true, + "license": "MIT" + }, + "node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "license": "MIT", + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/make-dir": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-4.0.0.tgz", + "integrity": "sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==", + "dev": true, + "license": "MIT", + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/make-dir/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/makeerror": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", + "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tmpl": "1.0.5" + } + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true, + "license": "MIT" + }, + "node_modules/micromatch": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", + "dev": true, + "license": "MIT", + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/mkdirp": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", + "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", + "dev": true, + "license": "MIT", + "bin": { + "mkdirp": "bin/cmd.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true, + "license": "MIT" + }, + "node_modules/natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", + "dev": true, + "license": "MIT" + }, + "node_modules/node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", + "dev": true, + "license": "MIT" + }, + "node_modules/node-releases": { + "version": "2.0.27", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz", + "integrity": "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==", + "dev": true, + "license": "MIT" + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dev": true, + "license": "ISC", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, + "license": "MIT", + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "license": "MIT", + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-locate/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "license": "MIT", + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true, + "license": "MIT" + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pirates": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.7.tgz", + "integrity": "sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 6" + } + }, + "node_modules/pkg-dir": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", + "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/prompts": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", + "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "kleur": "^3.0.3", + "sisteransi": "^1.0.5" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/pure-rand": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-6.1.0.tgz", + "integrity": "sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/dubzzz" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fast-check" + } + ], + "license": "MIT" + }, + "node_modules/react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true, + "license": "MIT" + }, + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/resolve": { + "version": "1.22.11", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.11.tgz", + "integrity": "sha512-RfqAvLnMl313r7c9oclB1HhUEAezcpLjz95wFH4LVuhk9JF/r22qmVP9AMmOU4vMX7Q8pN8jwNg/CSpdFnMjTQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-core-module": "^2.16.1", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/resolve-cwd": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", + "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", + "dev": true, + "license": "MIT", + "dependencies": { + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve.exports": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/resolve.exports/-/resolve.exports-2.0.3.tgz", + "integrity": "sha512-OcXjMsGdhL4XnbShKpAcSqPMzQoYkYyhbEaeSko47MjRP9NfEQMhZkXL1DoFlt9LWQn4YttrdnV6X2OiyzBi+A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + } + }, + "node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "license": "MIT", + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/sisteransi": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", + "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", + "dev": true, + "license": "MIT" + }, + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-support": { + "version": "0.5.13", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", + "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", + "dev": true, + "license": "MIT", + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/stack-utils": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", + "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "license": "MIT", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-bom": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", + "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/strip-json-comments": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", + "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/test-exclude": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", + "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", + "dev": true, + "license": "ISC", + "dependencies": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tmpl": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", + "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/undici-types": { + "version": "7.16.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.16.0.tgz", + "integrity": "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw==", + "dev": true, + "license": "MIT" + }, + "node_modules/update-browserslist-db": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz", + "integrity": "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "escalade": "^3.2.0", + "picocolors": "^1.1.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", + "dev": true, + "license": "MIT", + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/v8-to-istanbul": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz", + "integrity": "sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA==", + "dev": true, + "license": "ISC", + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.12", + "@types/istanbul-lib-coverage": "^2.0.1", + "convert-source-map": "^2.0.0" + }, + "engines": { + "node": ">=10.12.0" + } + }, + "node_modules/walker": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", + "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "makeerror": "1.0.12" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/write-file-atomic": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.2.tgz", + "integrity": "sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg==", + "dev": true, + "license": "ISC", + "dependencies": { + "imurmurhash": "^0.1.4", + "signal-exit": "^3.0.7" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/xml": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/xml/-/xml-1.0.1.tgz", + "integrity": "sha512-huCv9IH9Tcf95zuYCsQraZtWnJvBtLVE0QHMOs8bWyZAFZNDcYjsPq1nEx8jKA9y+Beo9v+7OBPRisQTjinQMw==", + "dev": true, + "license": "MIT" + }, + "node_modules/y18n": { + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=10" + } + }, + "node_modules/yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "dev": true, + "license": "ISC" + }, + "node_modules/yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dev": true, + "license": "MIT", + "dependencies": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=12" + } + }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 00000000..89e9aa1b --- /dev/null +++ b/package.json @@ -0,0 +1,15 @@ +{ + "name": "actions-template-tests", + "version": "0.0.0", + "private": true, + "description": "Unit tests for signalwire/actions-template shell scripts", + "scripts": { + "test": "jest --detectOpenHandles --forceExit", + "test:verbose": "jest --detectOpenHandles --forceExit --verbose", + "test:ci": "jest --detectOpenHandles --forceExit --ci --reporters=default --reporters=jest-junit" + }, + "devDependencies": { + "jest": "^29.7.0", + "jest-junit": "^16.0.0" + } +}