From a55ced6b7f22f21686e9ded2aa9fd7f1c39e31c7 Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Tue, 23 Apr 2019 16:50:19 +0200 Subject: [PATCH] Add a basic test to basic_boot --- tests/basic_boot.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/basic_boot.rs b/tests/basic_boot.rs index d737b4da..eb4a25ed 100644 --- a/tests/basic_boot.rs +++ b/tests/basic_boot.rs @@ -5,6 +5,7 @@ #![reexport_test_harness_main = "test_main"] use core::panic::PanicInfo; +use blog_os::{println, serial_print, serial_println}; #[no_mangle] // don't mangle the name of this function pub extern "C" fn _start() -> ! { @@ -17,3 +18,10 @@ pub extern "C" fn _start() -> ! { fn panic(info: &PanicInfo) -> ! { blog_os::test_panic_handler(info) } + +#[test_case] +fn test_println() { + serial_print!("test_println... "); + println!("test_println output"); + serial_println!("[ok]"); +}