feat(pty): add initial pty node

This commit is contained in:
Leroy Hopson 2024-02-24 19:47:12 +13:00
parent d223a458cd
commit 1514f42b54
No known key found for this signature in database
GPG key ID: D2747312A6DB51AA
21 changed files with 2819 additions and 71 deletions

21
test/test_pty.gd Normal file
View file

@ -0,0 +1,21 @@
# SPDX-FileCopyrightText: 2024 Leroy Hopson <godot-xterm@leroy.nix.nz>
# SPDX-License-Identifier: MIT
class_name PTYTest extends "res://addons/gut/test.gd"
var pty: PTY
func before_each():
pty = PTY.new()
add_child_autofree(pty)
class TestDefaults:
extends PTYTest
func test_default_env() -> void:
assert_eq(pty.env, {"TERM": "xterm-256color", "COLORTERM": "truecolor"})
func test_default_use_os_env() -> void:
assert_eq(pty.use_os_env, true)