diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2022-05-11 12:48:38 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-11 12:48:38 -0400 |
commit | 0ea6b51bf038108ba62577f7585bc76413f1f199 (patch) | |
tree | 7381a264701338196d0db4973ea971a1bf45ecdd /cli/tests/integration | |
parent | b67f874b3fb172168997be410b1d5e3c3109c763 (diff) |
fix: stdout and stderr encoding on Windows (#14559)
Diffstat (limited to 'cli/tests/integration')
-rw-r--r-- | cli/tests/integration/repl_tests.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/cli/tests/integration/repl_tests.rs b/cli/tests/integration/repl_tests.rs index 44036795f..0b69f8ebf 100644 --- a/cli/tests/integration/repl_tests.rs +++ b/cli/tests/integration/repl_tests.rs @@ -207,6 +207,20 @@ fn pty_assign_global_this() { } #[test] +fn pty_emoji() { + // windows was having issues displaying this + util::with_pty(&["repl"], |mut console| { + console.write_line("console.log('🦕');"); + console.write_line("close();"); + + let output = console.read_all_output(); + // one for input, one for output + let emoji_count = output.chars().filter(|c| *c == '🦕').count(); + assert_eq!(emoji_count, 2); + }); +} + +#[test] fn console_log() { let (out, err) = util::run_and_collect_output( true, |