mirror of
https://github.com/nushell/nushell.git
synced 2024-12-17 12:41:34 +01:00
change line format for test
This commit is contained in:
parent
b4977f1515
commit
767d822cbf
@ -6,9 +6,12 @@ pub struct ValueStream(pub Rc<RefCell<dyn Iterator<Item = Value>>>);
|
|||||||
|
|
||||||
impl ValueStream {
|
impl ValueStream {
|
||||||
pub fn into_string(self) -> String {
|
pub fn into_string(self) -> String {
|
||||||
|
format!(
|
||||||
|
"[{}]",
|
||||||
self.map(|x: Value| x.into_string())
|
self.map(|x: Value| x.into_string())
|
||||||
.collect::<Vec<String>>()
|
.collect::<Vec<String>>()
|
||||||
.join("\n")
|
.join(", ")
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn from_stream(input: impl Iterator<Item = Value> + 'static) -> ValueStream {
|
pub fn from_stream(input: impl Iterator<Item = Value> + 'static) -> ValueStream {
|
||||||
|
Loading…
Reference in New Issue
Block a user