From 53b4948a33d9066f1a742ba455ab819f70e058e7 Mon Sep 17 00:00:00 2001 From: ASuciuX Date: Tue, 5 Dec 2023 13:20:40 +0200 Subject: [PATCH] feat: changed flags on commit file because it doesn't retain it in cache --- .github/workflows/mutants.yml | 17 ++++++++++------- stx-genesis/src/lib.rs | 24 ------------------------ 2 files changed, 10 insertions(+), 31 deletions(-) diff --git a/.github/workflows/mutants.yml b/.github/workflows/mutants.yml index d1a6443404..8a374aa08e 100644 --- a/.github/workflows/mutants.yml +++ b/.github/workflows/mutants.yml @@ -30,9 +30,12 @@ jobs: path: ./mutation-testing/packages-output key: mutants-stable-develop + - name: Print old commit hash (before creating) + run: cat ./mutation-testing/last_commit_hash.txt + - name: Create file with current commit hash if it doesn't exist run: | - if [ ! -e last_commit_hash.txt ]; then + if [ ! -f last_commit_hash.txt ]; then echo "${{ github.sha }}" > last_commit_hash.txt fi working-directory: ./mutation-testing @@ -40,12 +43,12 @@ jobs: - name: Print old commit hash run: cat ./mutation-testing/last_commit_hash.txt - - name: Run the mutation testing on the differences - run: | - if [ -e last_commit_hash.txt ]; then - ./git-diff.sh - fi - working-directory: ./mutation-testing/scripts + # - name: Run the mutation testing on the differences + # run: | + # if [ -f last_commit_hash.txt ]; then + # ./git-diff.sh + # fi + # working-directory: ./mutation-testing/scripts - name: Re-write the old commit hash with the current one run: | diff --git a/stx-genesis/src/lib.rs b/stx-genesis/src/lib.rs index cd75f9c750..0c18ce300e 100644 --- a/stx-genesis/src/lib.rs +++ b/stx-genesis/src/lib.rs @@ -110,30 +110,6 @@ impl Iterator for LinePairReader { } } -fn fn_option_remove() -> Option { - Some(2) -} - -fn fn_int_remove() -> u32 { - 12 -} - -fn read_deflated_zonefiles_test_clone( - deflate_bytes: &'static [u8], -) -> Box> { - let cursor = io::Cursor::new(deflate_bytes); - let deflate_decoder = deflate::Decoder::new(cursor); - let buff_reader = BufReader::new(deflate_decoder); - let pairs = LinePairReader { - val: buff_reader.lines(), - }; - let pair_iter = pairs.into_iter().map(|pair| GenesisZonefile { - zonefile_hash: pair[0].to_owned(), - zonefile_content: pair[1].replace("\\n", "\n"), - }); - return Box::new(pair_iter); -} - fn read_deflated_zonefiles( deflate_bytes: &'static [u8], ) -> Box> {