adds unit tests react-component and react-directive

@davidchang this adds unit tests 
turns out the test did find an error :see_no_evil: