Skip to content

Add overwrite input test (#33) #13

Add overwrite input test (#33)

Add overwrite input test (#33) #13

Workflow file for this run

name: test
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
workflow_dispatch:
jobs:
directory:
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v4
- name: Targets specific directory
uses: ./
with:
directory: "tests/action/directory/a/*"
- name: Compare the minified files
run: git diff --exit-code
overwrite:
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v4
- name: Test successful overwrite
uses: ./
with:
directory: "tests/action/overwrite/overwritten/*"
overwrite: true
- name: Assert successful overwrite
run: |
git diff --exit-code tests/action/overwrite/overwritten/*
- name: Test failed overwrite
uses: ./
with:
directory: "tests/action/overwrite/not-overwritten/*"
overwrite: true
- name: Assert failed overwrite
run: |
! git diff --exit-code tests/action/overwrite/not-overwritten/*