extern crate thoughtfuck;
mod common;

use common::FauxStdout;
use thoughtfuck::vm::*;
use thoughtfuck::program::*;
use thoughtfuck::parse::parse;

#[test]
fn hello_world () {
    const SOURCE: &str = "++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++.";
    let commands = parse(SOURCE);

    let mut program = Program::new();
    program.append(&commands);

    let mut vm = VM::new(Some(Box::new(FauxStdout::new())));
    program.execute(&mut vm);
}

extern crate thoughtfuck;
mod common;

use thoughtfuck::vm::*;
use thoughtfuck::program::*;
use thoughtfuck::parse::parse;

#[test]
fn hello_world () {
    const SOURCE: &str = "++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++.";
    let commands = parse(SOURCE);

    let mut program = Program::new();
    program.append(&commands);

    let mut vm = VM::new(None);
    program.execute(&mut vm);
}

--- 
+++ 
@@ -1,6 +1,7 @@
 extern crate thoughtfuck;
 mod common;
 
+use common::FauxStdout;
 use thoughtfuck::vm::*;
 use thoughtfuck::program::*;
 use thoughtfuck::parse::parse;
@@ -13,6 +14,6 @@
     let mut program = Program::new();
     program.append(&commands);
 
-    let mut vm = VM::new(None);
+    let mut vm = VM::new(Some(Box::new(FauxStdout::new())));
     program.execute(&mut vm);
 }
Change test to instantiate VM with FauxStdout
