Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Intermittent failures running cargo test #144

Closed
joekain opened this issue Jul 4, 2015 · 2 comments
Closed

Intermittent failures running cargo test #144

joekain opened this issue Jul 4, 2015 · 2 comments

Comments

@joekain
Copy link
Contributor

joekain commented Jul 4, 2015

I was trying to track down some intermittent failures with some new tests I was writing and write a script to run cargo test over and over. With master I see 3 distinct failures signatures:

  1. This is due to an off-by-one error in sys::test_uio::test_readv. I have a change to fix this and will submit a PR.
    failures:

    ---- sys::test_uio::test_readv stdout ----
    thread 'sys::test_uio::test_readv' panicked at 'Rng.gen_range called with low >= high', /home/joseph/.cargo/registry/src/github.com-0a35038f75765ae4/rand-0.3.8/src/lib.rs:441
    
    
    
    failures:
    sys::test_uio::test_readv
    
  2. I think this is due to tests running tests in parallel and wait() waking up for a different child than expected. Is there a way to run tests in isolation?
    failures:

    ---- test_unistd::test_wait stdout ----
        thread 'test_unistd::test_wait' panicked at 'assertion failed: `(left == right)` (left: `Ok(Exited(21710))`, right: `Ok(Exited(21714))`)', test/test_unistd.rs:41
    
    
    ---- test_unistd::test_execve stdout ----
        thread 'test_unistd::test_execve' panicked at 'called `Result::unwrap()` on an `Err` value: Sys(ECHILD)', ../src/libcore/result.rs:731
    
    
    
    failures:
        test_unistd::test_execve
        test_unistd::test_wait
    
  3. This one takes longer to reproduce. I'm not sure what the problem is here.
    failures:

    ---- sys::test_termios::test_tcgetattr stdout ----
        thread 'sys::test_termios::test_tcgetattr' panicked at 'assertion failed: `(left == right)` (left: `Some(Sys(ENOTTY))`, right: `Some(Sys(EBADF))`)', test/sys/test_termios.rs:15
    
    
    
    failures:
        sys::test_termios::test_tcgetattr
    

Please let me know if I should file 3 separate issues for these.

joekain added a commit to joekain/nix-rust that referenced this issue Jul 4, 2015
Fix the boundary condition so that we never call

    Rng::gen_range(64, 64).

Helps nix-rust#144
This was referenced Jul 4, 2015
@carllerche
Copy link
Contributor

Merged this. Thanks!

@joekain
Copy link
Contributor Author

joekain commented Jul 8, 2015

Oops, I guess I should have filed 3 separate issues. Problems 2 and 3 still persist. I'll file new issues for them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants