added test for from and to json
filled in from and to json implementation