added test and added  global to be null
Merge pull request #22 from zelgerj/master

added test and added  global to be null