Added resource stream wrapper.
Cleaned up resource test.