From fbd3c92a885b02a5397eaf65d36beae8e1ed999c Mon Sep 17 00:00:00 2001 From: Gabriel Majeri Date: Tue, 5 Jun 2018 08:50:06 +0300 Subject: [PATCH] Add run-pass test --- src/test/run-pass/issue-49854.rs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/test/run-pass/issue-49854.rs diff --git a/src/test/run-pass/issue-49854.rs b/src/test/run-pass/issue-49854.rs new file mode 100644 index 0000000000000..5bb80b5e2c6a1 --- /dev/null +++ b/src/test/run-pass/issue-49854.rs @@ -0,0 +1,18 @@ +// Copyright 2018 The Rust Project Developers. See the COPYRIGHT +// file at the top-level directory of this distribution and at +// http://rust-lang.org/COPYRIGHT. +// +// Licensed under the Apache License, Version 2.0 or the MIT license +// , at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + +use std::ffi::OsString; + +fn main() { + let os_str = OsString::from("Hello Rust!"); + + assert_eq!(os_str, "Hello Rust!"); + assert_eq!("Hello Rust!", os_str); +}