Miserlou / Miserlou/Loop

Errors running `cargo test`

Open
#72 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
697
Forks
28
PR merge metrics
No merged PRs in 30d

Description

$ rustup show
Default host: x86_64-unknown-linux-gnu
rustup home:  /home/foobar/.rustup

stable-x86_64-unknown-linux-gnu (default)
rustc 1.63.0 (4b91a6ea7 2022-08-08)
$ cargo test

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s


running 11 tests
test item ... ok
test no_of_iterations ... ok
test only_last ... ok
test summary ... FAILED
test until_changes ... ok
test until_error ... FAILED
test until_contains ... ok
test until_fail ... FAILED
test until_success ... FAILED
test until_same ... FAILED
test counter ... ok

failures:

---- summary stdout ----
thread 'summary' panicked at 'Unexpected stdout, failed diff original var
├── original: Total runs:	3
│   Successes:	2
│   Failures:	1 (-1)
├── diff:
│   --- 	orig
│   +++ 	var
│   @@ -3 +3 @@
│   -Failures:	1 (-1)
│   +Failures:	1 (1)
└── var as str: Total runs:	3
    Successes:	2
    Failures:	1 (1)

command=`"/home/foobar/src/contrib/Loop/target/debug/loop" "--for=true,false,true" "--summary" "--" "$ITEM"`
code=0
stdout=```"Total runs:\t3\nSuccesses:\t2\nFailures:\t1 (1)\n"```
stderr=```""```
', /home/foobar/.cargo/registry/src/github.com-1ecc6299db9ec823/assert_cmd-1.0.8/src/assert.rs:124:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

---- until_error stdout ----
thread 'until_error' panicked at 'Unexpected failure.
code-1
stderr=```"error: The argument \'--until-error <until_error>\' requires a value but none was supplied\n\nUSAGE:\n    loop --count-by <count_by> --every <every> --for <ffor> --offset <offset> --summary --until-error <until_error>\n\nFor more information try --help\n"```
command=`"/home/foobar/src/contrib/Loop/target/debug/loop" "--for=true,true,false,true,true,true" "--until-error" "--summary" "--" "$ITEM"`
code=1
stdout=```""```
stderr=```"error: The argument \'--until-error <until_error>\' requires a value but none was supplied\n\nUSAGE:\n    loop --count-by <count_by> --every <every> --for <ffor> --offset <offset> --summary --until-error <until_error>\n\nFor more information try --help\n"```
', /home/foobar/.cargo/registry/src/github.com-1ecc6299db9ec823/assert_cmd-1.0.8/src/assert.rs:124:9

---- until_fail stdout ----
thread 'until_fail' panicked at 'Unexpected stdout, failed diff original var
├── original: Total runs:	3
│   Successes:	2
│   Failures:	1 (-1)
├── diff:
│   --- 	orig
│   +++ 	var
│   @@ -3 +3 @@
│   -Failures:	1 (-1)
│   +Failures:	1 (1)
└── var as str: Total runs:	3
    Successes:	2
    Failures:	1 (1)

command=`"/home/foobar/src/contrib/Loop/target/debug/loop" "--for=true,true,false,true,true,true" "--until-fail" "--summary" "--" "$ITEM"`
code=0
stdout=```"Total runs:\t3\nSuccesses:\t2\nFailures:\t1 (1)\n"```
stderr=```""```
', /home/foobar/.cargo/registry/src/github.com-1ecc6299db9ec823/assert_cmd-1.0.8/src/assert.rs:124:9

---- until_success stdout ----
thread 'until_success' panicked at 'Unexpected stdout, failed diff original var
├── original: Total runs:	4
│   Successes:	1
│   Failures:	3 (-1, -1, -1)
├── diff:
│   --- 	orig
│   +++ 	var
│   @@ -3 +3 @@
│   -Failures:	3 (-1, -1, -1)
│   +Failures:	3 (1, 1, 1)
└── var as str: Total runs:	4
    Successes:	1
    Failures:	3 (1, 1, 1)

command=`"/home/foobar/src/contrib/Loop/target/debug/loop" "--for=false,false,false,true,false,false" "--until-success" "--summary" "--" "$ITEM"`
code=0
stdout=```"Total runs:\t4\nSuccesses:\t1\nFailures:\t3 (1, 1, 1)\n"```
stderr=```""```
', /home/foobar/.cargo/registry/src/github.com-1ecc6299db9ec823/assert_cmd-1.0.8/src/assert.rs:124:9

---- until_same stdout ----
thread 'until_same' panicked at 'Unexpected stdout, failed diff original var
├── original: 5
├── diff:
│   --- 	orig
│   +++ 	var
│   @@ -1 +1 @@
│   -5
│   +7
└── var as str: 7

command=`"/home/foobar/src/contrib/Loop/target/debug/loop" "--for=1,2,3,4,5,5,6,7" "--until-same" "--only-last" "--" "echo $ITEM"`
code=0
stdout=```"7\n"```
stderr=```""```
', /home/foobar/.cargo/registry/src/github.com-1ecc6299db9ec823/assert_cmd-1.0.8/src/assert.rs:124:9


failures:
    summary
    until_error
    until_fail
    until_same
    until_success

test result: FAILED. 6 passed; 5 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.04s

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running cargo test and focus on the failing tests: summary, until_error, until_fail, until_success, and until_same. Compare their reported output and argument handling with the expectations shown in the issue; done means the test suite passes with the expected summaries and values.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.