Fix `The "path" argument must be of type string. Received an instance… #17
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: [push] | |
jobs: | |
empty_data: | |
runs-on: ubuntu-latest | |
name: Test for no output file with no input data | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Test | |
uses: ./ | |
with: | |
out-file: output.json | |
- name: Check output file presence | |
shell: bash | |
run: | | |
if [ -f 'output.json' ]; then | |
echo "There is still an output file, this is incorrect" | |
exit 1 | |
else | |
echo "No output file" | |
fi | |
non_exist: | |
runs-on: ubuntu-latest | |
name: Test with non-existent file and directory on input | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Test | |
uses: ./ | |
with: | |
in-file: asdf_file | |
in-directory: asdf_dir | |
out-file: output.json | |
file_to_file: | |
runs-on: ubuntu-latest | |
name: Test just copying the file | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Test | |
uses: ./ | |
with: | |
in-file: test/file.json | |
out-file: output_single.json | |
- name: Print output | |
shell: bash | |
run: | | |
wc -c < output_single.json | |
cat output_single.json | |
echo | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: output_single | |
path: output_single.json | |
json_merging: | |
runs-on: ubuntu-latest | |
name: Test merging logic | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Test | |
uses: ./ | |
with: | |
in-file: test/file.json | |
in-directory: test/file | |
out-file: output.json | |
- name: Print output | |
shell: bash | |
run: | | |
wc -c < output.json | |
cat output.json | |
echo | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: output | |
path: output.json |