{"action":"created","issue":{"url":"https://api.github.com/repos/influxdb/influxdb/issues/1490","labels_url":"https://api.github.com/repos/influxdb/influxdb/issues/1490/labels{/name}","comments_url":"https://api.github.com/repos/influxdb/influxdb/issues/1490/comments","events_url":"https://api.github.com/repos/influxdb/influxdb/issues/1490/events","html_url":"https://github.com/influxdb/influxdb/pull/1490","id":56315910,"number":1490,"title":"Basic integration testing","user":{"login":"corylanou","id":585100,"avatar_url":"https://avatars.githubusercontent.com/u/585100?v=3","gravatar_id":"","url":"https://api.github.com/users/corylanou","html_url":"https://github.com/corylanou","followers_url":"https://api.github.com/users/corylanou/followers","following_url":"https://api.github.com/users/corylanou/following{/other_user}","gists_url":"https://api.github.com/users/corylanou/gists{/gist_id}","starred_url":"https://api.github.com/users/corylanou/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/corylanou/subscriptions","organizations_url":"https://api.github.com/users/corylanou/orgs","repos_url":"https://api.github.com/users/corylanou/repos","events_url":"https://api.github.com/users/corylanou/events{/privacy}","received_events_url":"https://api.github.com/users/corylanou/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/influxdb/influxdb/labels/2%20-%20Working","name":"2 - Working","color":"CCCCCC"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-02-03T00:30:28Z","updated_at":"2015-02-04T17:21:52Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/influxdb/influxdb/pulls/1490","html_url":"https://github.com/influxdb/influxdb/pull/1490","diff_url":"https://github.com/influxdb/influxdb/pull/1490.diff","patch_url":"https://github.com/influxdb/influxdb/pull/1490.patch"},"body":"This adds an integration test that spins up a server in memory and does the following:\r\n\r\n- Creates a database\r\n- Creates a default retention policy\r\n- Writes data\r\n- Queries data\r\n\r\nTwo bugs were discovered during this refactoring.\r\n\r\n1) We were sending back all time in microseconds.  This was due to a legacy business decision.  This has been fixed in PR https://github.com/influxdb/influxdb/pull/1487.\r\n\r\n2) We had removed `json.UseNumber()` in a previous pr (https://github.com/influxdb/influxdb/pull/1384).  This was needed to stop the server from panicing.  The cause was due to the `shard.marshalValues` could only decode `float64`.  `json.UseNumber()` sends in data as a `json.Number`.  I created a normalization function that converts all json data from `json.Number` to `float64` before writing to the database to fix this.\r\n\r\nOne additional refactoring was in the `cmd/influxd` package where I teased out `execRun` from `Run` only for the purpose of creating integration tests without the need for physical config files."},"comment":{"url":"https://api.github.com/repos/influxdb/influxdb/issues/comments/72897350","html_url":"https://github.com/influxdb/influxdb/pull/1490#issuecomment-72897350","issue_url":"https://api.github.com/repos/influxdb/influxdb/issues/1490","id":72897350,"user":{"login":"otoolep","id":536312,"avatar_url":"https://avatars.githubusercontent.com/u/536312?v=3","gravatar_id":"","url":"https://api.github.com/users/otoolep","html_url":"https://github.com/otoolep","followers_url":"https://api.github.com/users/otoolep/followers","following_url":"https://api.github.com/users/otoolep/following{/other_user}","gists_url":"https://api.github.com/users/otoolep/gists{/gist_id}","starred_url":"https://api.github.com/users/otoolep/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/otoolep/subscriptions","organizations_url":"https://api.github.com/users/otoolep/orgs","repos_url":"https://api.github.com/users/otoolep/repos","events_url":"https://api.github.com/users/otoolep/events{/privacy}","received_events_url":"https://api.github.com/users/otoolep/received_events","type":"User","site_admin":false},"created_at":"2015-02-04T17:21:51Z","updated_at":"2015-02-04T17:21:51Z","body":"@corylanou - what I mean is that as long as you are sure you have not broken 1 node joining another, since this touches production code. Make sense?"}}