input: refactor, move dsl stuff to tek config
Some checks are pending
/ build (push) Waiting to run

This commit is contained in:
🪞👃🪞 2025-08-23 13:47:45 +03:00
parent 0621793930
commit e3e3c163da
12 changed files with 104 additions and 182 deletions

28
input/input_test.rs Normal file
View file

@ -0,0 +1,28 @@
use crate::*;
#[test] fn test_stub_input () -> Usually<()> {
use crate::*;
struct TestInput(bool);
enum TestEvent { Test1 }
impl Input for TestInput {
type Event = TestEvent;
type Handled = ();
fn event (&self) -> &Self::Event {
&TestEvent::Test1
}
fn is_done (&self) -> bool {
self.0
}
fn done (&self) {}
}
let _ = TestInput(true).event();
assert!(TestInput(true).is_done());
assert!(!TestInput(false).is_done());
Ok(())
}
//#[cfg(all(test, feature = "dsl"))] #[test] fn test_dsl_keymap () -> Usually<()> {
//let _keymap = CstIter::new("");
//Ok(())
//}