mirror of
https://github.com/rust-lang/rustlings.git
synced 2026-03-31 03:29:19 +00:00
Add backtrace to CI
This commit is contained in:
parent
8738518699
commit
aaf8cad778
2
.github/workflows/rust.yml
vendored
2
.github/workflows/rust.yml
vendored
@ -37,7 +37,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v6
|
- uses: actions/checkout@v6
|
||||||
- uses: swatinem/rust-cache@v2
|
- uses: swatinem/rust-cache@v2
|
||||||
- name: cargo test
|
- name: cargo test
|
||||||
run: cargo test --workspace
|
run: RUST_BACKTRACE=1 cargo test --workspace
|
||||||
dev-check:
|
dev-check:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
|
|||||||
@ -38,6 +38,7 @@ impl<'a> Cmd<'a> {
|
|||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[track_caller]
|
||||||
fn assert(&self, success: bool) {
|
fn assert(&self, success: bool) {
|
||||||
let rustlings_bin = {
|
let rustlings_bin = {
|
||||||
let mut path = env::current_exe().unwrap();
|
let mut path = env::current_exe().unwrap();
|
||||||
@ -87,11 +88,13 @@ impl<'a> Cmd<'a> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
|
#[track_caller]
|
||||||
fn success(&self) {
|
fn success(&self) {
|
||||||
self.assert(true);
|
self.assert(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
|
#[track_caller]
|
||||||
fn fail(&self) {
|
fn fail(&self) {
|
||||||
self.assert(false);
|
self.assert(false);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user