Update github-actions - #324
Merged
Merged
Conversation
|
|
||
| - name: "Install bashunit" | ||
| uses: "TypedDevs/bashunit@2b87bad44cc15d8f7afdd3b1506ecc4554fba705" # 0.45.0 | ||
| uses: "TypedDevs/bashunit@81fb3e1d146eef12d0e728cb3b542fe00dee906e" # 0.49.0 |
| - name: Generate changelog | ||
| id: changelog | ||
| uses: metcalfc/changelog-generator@0440d0932f9a0dd1cc9ecd8412830761351323bd # v4.7.0 | ||
| uses: metcalfc/changelog-generator@98b12822c5dc6bad335d1d60d920cb69831b9c5d # v4.8.0 |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
0.45.0→0.49.0v4.37.6→v4.37.7v4.7.0→v4.8.0v2.20.1→v2.21.0Warning
Some dependencies could not be looked up. Check the Dependency Dashboard for more information.
Release Notes
TypedDevs/bashunit (TypedDevs/bashunit)
v0.49.0Compare Source
Added
--pass-with-no-testsexits 0 when a run selects no tests, for the case where that is deliberate — a CI matrix whose shards are not all populated, or a changed-files run that touched no tests. The run still reportsNo tests found; only the verdict changes. It does not excuse a path that is not on disk. Same flag, same spelling, as jest, vitest, Playwright and Cypress (#1263)--list-tagsprints the tags of the selected files, one per line, sorted and deduplicated, and runs nothing. Tags live only in# @tagcomments, so a mistyped--taghad no list to check against (#1265)Changed
testorbenchpath that does not exist is now named and refused before the run starts, instead of theNo tests found/No benchmarks foundan empty selection gives. Every genuinely-empty case keeps that message: a directory holding no tests, a--filteror--tagmatching nothing, an empty--shard,--changedwith no changes, and a glob the shell left unexpanded (#1263)BASHUNIT_DEFAULT_PATH.bashunit empty_dir/ran the default suite and exited 0, reporting a pass for tests the caller never named (#1263)--snapshot-report-unusedand--snapshot-prunenow report a snapshot whose test file was deleted or renamed — the most common way one is orphaned, and the only kind neither flag could ever see. One whose file exists but was not part of this run is still left alone. This widens what--snapshot-prunedeletes (#1194)--tagmatching nothing now names the tags the run saw, or says no test carries one (#1265)BASHUNIT_TEMP_DIR, which is shared and survives between runs — a 100-test file went from 978ms to 542ms against 5000 leftovers, and runtime no longer grows with that directory. A file a test writes there by hand, rather than viatemp_file/temp_dir, is no longer removed for it (#1269)Fixed
riskywhile still exiting 0: 120 files under a 120-descriptor limit ran 2 assertions instead of 120 (#1271)Time takenno longer reports0ms, or a negative duration, for a runtime it could not measure — both read as real measurements. It now saysunknown(#1271)--test-timeoutno longer leaves its watchdog holding the caller's captured output for the rest of the timeout budget; a nested run under--suitedid this to the run that spawned it (#1137)--listunder--parallelno longer printsNo tests foundin the middle of the ids: a listing dispatches no worker, so there is nothing to aggregate (#1007)v0.48.0Compare Source
Added
--verbosewarns on Bash 3.x that coverage does not count lines run inside a subshell, so a lower percentage there explains itself (#1112)Changed
--coverageis roughly 5x faster and--coverage-report-htmlroughly 19x — this repo went from 16.2s to 2.9s, and a 128-file HTML report from 58.7s to 3.1s (#1092, #1096, #1098, #1099, #1102, #1104, #1110, #1117)./build.shis about 1.9x faster (7.6s to 4.0s), producing a byte-identical artifact (#1233)Failuressection with each failure's name,file:lineand message, and its summary now counts risky and flaky tests (#1251, #1252)--filterthat matches nothing names the test it most likely meant: filters match the test function name, case-sensitively, not the humanized title in the report (#1237)--envwith a space in the path now says the value was split on the first space to pass bootstrap arguments, and thatBASHUNIT_BOOTSTRAPtakes the path whole (#1247)cannot readfor all of them (#1262)bashunit doc <filter>saysNo assertion matches '<filter>'instead of printing nothing (#1201)install.shdestination errors no longer advise a-dflag that does not exist; the script takes positional arguments (#1221)bashunit learngenerates starter files that are valid bash, and verifies lessons against the learner's code rather than the hint comments in its own template (#1256, #1258)|,<or&(#1254)example/demo is covered by the suite; nothing ran it before (#1219)bashunit bench [path]subcommand —-s -band--simple --benchnever existed (#1227)test_prefix; the guide's camelCase example and its case-insensitive claim were both wrong (#1215)assert_equalsstrips ANSI codes, tabs and newlines — not spaces (#1225)-e/--env/--bootfile assigns an empty value; it does not restore the default (#1217)assert_matchescosts ~2.5ms per call against ~0.065ms forassert_same, so preferassert_containsfor a fixed substring (#1187)@data_providertest shares one snapshot across all its values; useassert_match_named_snapshot "$1"for one each (#1185)Fixed
bashunit --output junitproduces valid XML, and--parallel --stop-on-failureno longer corrupts a machine--outputstream (#1239, #1243)--coverage-pathsaccepts a path containing a space, an apostrophe or a glob character; it used to break the DEBUG trap and fail passing tests (#1245)--parallelrun no longer emits a stray\r \r, and an empty one renders its notice on its own line (#1239)--parallelagain; the run reported "All tests passed" over a file where one of two same-named tests never ran (#1147)@data_providerthat is undefined or yields no data is reported as an error naming the provider, instead of the test vanishing behind "No tests found" (#1145)bashunit benchreportsNo benchmarks foundand exits non-zero when the path does not exist or holds nobench_function (#1199)is a directory, not a fileinstead of exiting 0 with no report written (#1177)--coverage-paths, instead of reportingCoverage 0% is below minimum N%(#1171)assert_exec "cmd" --exit 1works under--strict;set -eaborted the test before the assertion could read the code (#1207)assert_equalsno longer expands backslash escapes while normalizing, soC:\andC:\\differ and a literal\tis not a real tab (#1108)assert_file_containsaccepts a needle starting with a dash, andassert_file_not_containsmatches literally like its counterpart (#1108)bashunit::mock, notmock), and reports a usable-name error instead of a raw bash syntax error (#1136, #1229)jqis reported under its own name, notbashunit::assert_json::require_jq(#1223)install.shnames the real problem when the destination is unusable, and validates it before any network call (#1197)bashunit initno longer adds a deadBASHUNIT_BOOTSTRAPline to.envon every run, and reports what it wrote (#1175)#in a test name, socheck # SKIP meis no longer read as a directive (#1119)v0.47.0Compare Source
Added
--output <text|tap|json|junit>prints the JSON and JUnit reports on stdout, so a pipeline needs no temp file;--report-jsonstill writes its file alongside (#1018)bashunit::skip_if,bashunit::skip_unless,bashunit::skip_unless_command <cmd>andbashunit::skip_on <windows|macos|linux>mark a test skipped and end it, replacingbashunit::skip && return(#1019)# @timeout <seconds>,# @retry <n>and# @skip [reason]annotations override the run-wide flags in both directions; a malformed value aborts the run (#1020)[suite:<name>]sections in.bashunitrcname a set of paths and options;--suite <name>runs one (repeatable) and--list-suiteslists them (#1021)--sandboxfails a test that runs an external command it did not mock, and--sandbox-allow <cmd,...>widens the baseline allowlist (ADR-012) (#1022)bashunit::mock_sequence <cmd> <answer>…answers each call with the next entry, so retry loops need no hand-rolled counter file; the last entry repeats once exhausted (#1023)assert_have_never_been_called <cmd>asserts a spied command never ran, printing the recorded calls when it did (#1023)assert_is_file_readable,assert_is_file_writable,assert_is_file_executable, their negatives andassert_is_file_not_emptygive files the parity directories already had (#1024)assert_json_key_not_existschecks that a JSON path is absent, andassert_json_lengththe size of an array, object or string (#1025)bashunit bench --report-json <file>and--report-junit <file>write the benchmark run to disk, so a CI run leaves an artifact to store, chart and compare (#1028)bashunit bench --baseline <file>fails a run when a benchmark is more than--baseline-tolerancepercent (default 10) slower than the recorded one, comparing medians;--baseline-update <file>records the new reference (#1029)--snapshot-prunedeletes the snapshot files no test resolved, printing every path; full runs only, and never on a run with failures (#1030)Changed
BRDAcarries the arm's execution count instead of a 0/1 taken flag, taken from the arm's first executable line;BRFandBRHare unchanged (#1061)--coverageis about 10x faster — a run over this repo'ssrcwent from 9.23s to 0.96s. The report phase classifies lines, scans declarations and branches and emits the whole LCOV report in one awk invocation per run instead of Bash loops and forks per file, hit data is grouped once, the DEBUG trap rejects untracked lines before recording, and the caches are read through the variable table (#1056, #1057, #1059, #1060, #1084, #1088, #1090)Fixed
--coverage-paths, not only the ones a test executed: an untouched file shows as0/N (0%)and--coverage-mingates on that denominator. This repo reported 11 of its own 121 files. Percentages drop, because the old ones were measured over the files that ran (#1053)--coverage-diffcounts a changed file that no test executed, instead of skipping it and letting a brand new untested file pass a--coverage-min 90gate. A docs-only commit still reports 100% (#1054))as acasearm, sox=$(foo)left the denominator whilex=$(printf '%s\n')stayed. A)now closes an arm only when no(opened earlier on the line, recovering 456 executable lines of this repo'ssrc/. Percentages move in both directions per file (#1055){stops swallowing every later function in the file — 11 functions in this repo'ssrc/coverage/lines.shwere reported as 1, andEND {inside an embedded awk program was reported as a function.FN,FNDA,FNFandFNHchange; lines and branches do not (#1086)v0.46.0Compare Source
Added
--changed [<ref>]runs only the test files git reports as touched since<ref>(defaultorigin/HEAD, thenHEAD), covering committed, staged, unstaged and untracked changes (#1010)--order-by <defined|defects|random>picks the execution order;defectsruns the last run's failures first and still runs the whole suite (#1011)--list(alias--dry-run) prints the tests a run would execute without running them;--list-format jsonemits file, function, name, line and tags, honouring every selection flag including--shard(#1007)--exclude-filter <name>skips tests by name, the counterpart of--exclude-tag: repeatable, OR'd, and wins over--filter(#1009)--tagaccepts expressions:'a&&b'(AND),'!a'(NOT) and'a&&!b'; repeated--tagflags keep OR semantics and--exclude-tagstill wins (#1008)# @tags a babove any top-level line tags every test in the file, unioned with per-function# @tag(#1008)--repeat <n>runs each selected test n times to hunt flakiness before CI does: one report line with the aggregate outcome, a failure names its iteration, and repeat wraps--retry(#1013)<flakyFailure>), TAP, JSON, HTML and GitHub Actions with the first attempt's failure message;--fail-on-flakyturns such a run red (#1012)--coverage-report-cobertura [file]writes Cobertura XML (defaultcoverage/cobertura.xml), the format GitLab merge-request visualisation, Azure DevOps and Jenkins consume, with repo-relative filenames, per-line hits andcondition-coverageon branch lines, alongside the LCOV and HTML reports (#1017)--coverage-diff <ref>limits the coverage console report to lines changed since a base ref;--coverage-minthen gates on that diff percentage (#1032)--report-md <file>writes a Markdown run summary — verdict, counts table, failures with their message, plus coverage and slowest tests when those ran — and inside GitHub Actions appends it to$GITHUB_STEP_SUMMARY(#1015)--gha-annotations <auto|always|never>overrides the detection andaction.ymlgains anannotationsinput (#1014)assert_between <min> <max> <actual>andassert_not_betweenadd inclusive numeric-range assertions for integers and decimals (#1026)assert_command_available <command>asserts a command, shell builtin or function resolves throughcommand -v(#1027)--verbosereports the coverage engine in use, and an explicitBASHUNIT_COVERAGE_ENGINE=xtracethe running Bash cannot honour now warns instead of being silently ignored (#1005)Changed
<testsuite>per test file with its own counts, time and timestamp instead of a single flat suite,classnameon every<testcase>,<failure message="...">carrying the first informative line of the real message withtype="AssertionFailed",<system-out>with the test's captured output, and aggregate totals on<testsuites>, so consumers that group by suite or classname (Jenkins, GitLab, dorny/test-reporter) get real groupings (#1016)--coverageis about 1.6x to 2.3x faster; executable-line classification no longer forksgrepper source line, roughly half of a coverage run's wall time on both engines (#1005)bashunit test --helplists--show-skippedand--show-incomplete, both accepted by the parser but never advertised;BASHUNIT_COVERAGE_SHOW_FUNCTIONSandBASHUNIT_COVERAGE_SHOW_UNCOVEREDare registered insrc/config/env.shlike every other setting, and.env.examplenow lists all 66 settings, 19 of which were missing (#1063)docs/configuration.mdgained the 17 settings it never documented,docs/command-line.mdgained theassertsubcommand section and real example output, and the coverage settings and diff-coverage narrative now live in one place instead of two that had drifted (#1063)Fixed
--parallel;--report-junit,--report-tap,--report-json,--report-htmland--log-junitall recorded zero tests, because the rows were collected inside the per-test worker and nothing rebuilt them in the parent (#1004)bashunit::assert_thatreturns 1 on failure by design, so a custom assertion ending with it made the test body exit non-zero and the runner printed a spurious✗ Erroron top of the✗ Failed. Custom assertions no longer need a trailingreturn 0, and a real runtime error is still reported as an error (#1063)--coverage-reportwith no value usescoverage/lcov.infoinstead of aborting the run with$2: unbound variable, and no longer consumes a following flag as its filename; write the test path before it, since an optional value cannot be told apart from a path (#1063)--list --list-format jsonreports each tag as its own array element; the emitter split the tag list on whitespace while every other consumer splits it on commas, so two tags rendered as["slow,fileTag"](#1063)assert_within_deltarejects malformed numbers such as1.2.3or5-3as non-numeric instead of leaking a rawbcparse error or evaluating them as an expression (#1026)github/codeql-action (github/codeql-action)
v4.37.7Compare Source
metcalfc/changelog-generator (metcalfc/changelog-generator)
v4.8.0Compare Source
Highlights
Failed changelog generation now fails the step
If the changelog could not be generated — an unresolvable ref, any git error — the action printed an
::error::annotation and then exited 0. The step went green,outputs.changelogwas never set, and downstream steps consumed an empty string without anything indicating a problem.It now exits non-zero.
fetch: trueno longer intermittently fails on shallow checkoutsThe default fetch path chained two
git fetch --depth=1calls ahead ofgit fetch --unshallow. Each rewrites.git/shallowwhile the next has already read it, so git would intermittently abort with:Because
fetch: trueis the default and the exit code was being discarded, this produced a silently empty changelog rather than a visible failure. It was happening in this repository's own CI.Now a single fetch, requesting
--unshallowonly when the checkout is actually shallow.Testing
make testpreviously rannpm test || echo "no tests available", wherenpm testwasexit 1— it reported success unconditionally. The project now has a real suite coveringchangelog.shagainst live git fixtures, ref validation, the release scripts, and the builtdist/bundle as the runner executes it. Both fixes above were found by adding it.Full changelog
step-security/harden-runner (step-security/harden-runner)
v2.21.0Compare Source
What's Changed
Full Changelog: step-security/harden-runner@v2.20.1...v2.21.0
Configuration
📅 Schedule: (UTC)
* 0-3 * * 1)🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.
This PR was generated by Mend Renovate. View the repository job log.