Fixes test which are now run due to should_panic
Since I changed no_run to should_panic on some tests, the were run but two lacked an actual assertion. Further, I missed to check the return type on another test.
This commit is contained in:
@@ -314,6 +314,8 @@ impl Command {
|
|||||||
/// println!("status: {}", output.status);
|
/// println!("status: {}", output.status);
|
||||||
/// println!("stdout: {}", String::from_utf8_lossy(&output.stdout));
|
/// println!("stdout: {}", String::from_utf8_lossy(&output.stdout));
|
||||||
/// println!("stderr: {}", String::from_utf8_lossy(&output.stderr));
|
/// println!("stderr: {}", String::from_utf8_lossy(&output.stderr));
|
||||||
|
///
|
||||||
|
/// assert!(output.status.success());
|
||||||
/// ```
|
/// ```
|
||||||
#[stable(feature = "process", since = "1.0.0")]
|
#[stable(feature = "process", since = "1.0.0")]
|
||||||
pub fn output(&mut self) -> io::Result<Output> {
|
pub fn output(&mut self) -> io::Result<Output> {
|
||||||
@@ -335,6 +337,8 @@ impl Command {
|
|||||||
/// .expect("failed to execute process");
|
/// .expect("failed to execute process");
|
||||||
///
|
///
|
||||||
/// println!("process exited with: {}", status);
|
/// println!("process exited with: {}", status);
|
||||||
|
///
|
||||||
|
/// assert!(status.success());
|
||||||
/// ```
|
/// ```
|
||||||
#[stable(feature = "process", since = "1.0.0")]
|
#[stable(feature = "process", since = "1.0.0")]
|
||||||
pub fn status(&mut self) -> io::Result<ExitStatus> {
|
pub fn status(&mut self) -> io::Result<ExitStatus> {
|
||||||
@@ -518,7 +522,7 @@ impl Child {
|
|||||||
/// let ecode = child.wait_with_output()
|
/// let ecode = child.wait_with_output()
|
||||||
/// .expect("failed to wait on child");
|
/// .expect("failed to wait on child");
|
||||||
///
|
///
|
||||||
/// assert!(ecode.success());
|
/// assert!(ecode.status.success());
|
||||||
/// ```
|
/// ```
|
||||||
///
|
///
|
||||||
#[stable(feature = "process", since = "1.0.0")]
|
#[stable(feature = "process", since = "1.0.0")]
|
||||||
|
|||||||
Reference in New Issue
Block a user