Add to json tests

added specs  for to_json
added spec for the case of to_hash with nils allowed
converting syntax to : instead of hashrockets