aboutsummaryrefslogtreecommitdiffstats
path: root/tests/osc.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/osc.rs')
-rw-r--r--tests/osc.rs17
1 files changed, 7 insertions, 10 deletions
diff --git a/tests/osc.rs b/tests/osc.rs
index be3c476..001ad53 100644
--- a/tests/osc.rs
+++ b/tests/osc.rs
@@ -1,15 +1,12 @@
-mod support;
-use support::TestHelpers;
-
#[test]
fn title() {
let mut screen = vt100::Screen::new(24, 80);
assert!(screen.title().is_none());
assert!(screen.icon_name().is_none());
- screen.assert_process(b"\x1b]2;it's a title\x07");
+ screen.process(b"\x1b]2;it's a title\x07");
assert_eq!(screen.title().unwrap(), "it's a title");
assert!(screen.icon_name().is_none());
- screen.assert_process(b"\x1b]2;\x07");
+ screen.process(b"\x1b]2;\x07");
assert_eq!(screen.title().unwrap(), "");
assert!(screen.icon_name().is_none());
}
@@ -19,10 +16,10 @@ fn icon_name() {
let mut screen = vt100::Screen::new(24, 80);
assert!(screen.title().is_none());
assert!(screen.icon_name().is_none());
- screen.assert_process(b"\x1b]1;it's an icon name\x07");
+ screen.process(b"\x1b]1;it's an icon name\x07");
assert!(screen.title().is_none());
assert_eq!(screen.icon_name().unwrap(), "it's an icon name");
- screen.assert_process(b"\x1b]1;\x07");
+ screen.process(b"\x1b]1;\x07");
assert!(screen.title().is_none());
assert_eq!(screen.icon_name().unwrap(), "");
}
@@ -32,10 +29,10 @@ fn title_icon_name() {
let mut screen = vt100::Screen::new(24, 80);
assert!(screen.title().is_none());
assert!(screen.icon_name().is_none());
- screen.assert_process(b"\x1b]0;it's both\x07");
+ screen.process(b"\x1b]0;it's both\x07");
assert_eq!(screen.title().unwrap(), "it's both");
assert_eq!(screen.icon_name().unwrap(), "it's both");
- screen.assert_process(b"\x1b]0;\x07");
+ screen.process(b"\x1b]0;\x07");
assert_eq!(screen.title().unwrap(), "");
assert_eq!(screen.icon_name().unwrap(), "");
}
@@ -44,6 +41,6 @@ fn title_icon_name() {
fn unknown_sequence() {
let mut screen = vt100::Screen::new(24, 80);
assert_eq!(screen.cell(0, 0).unwrap().contents(), "");
- screen.assert_process(b"\x1b]499;some long, long string?\x07");
+ screen.process(b"\x1b]499;some long, long string?\x07");
assert_eq!(screen.cell(0, 0).unwrap().contents(), "");
}