{"action":"created","issue":{"url":"https://api.github.com/repos/restic/restic/issues/179","labels_url":"https://api.github.com/repos/restic/restic/issues/179/labels{/name}","comments_url":"https://api.github.com/repos/restic/restic/issues/179/comments","events_url":"https://api.github.com/repos/restic/restic/issues/179/events","html_url":"https://github.com/restic/restic/pull/179","id":74666270,"number":179,"title":"Add integration test with the go testing framework","user":{"login":"fd0","id":123276,"avatar_url":"https://avatars.githubusercontent.com/u/123276?v=3","gravatar_id":"","url":"https://api.github.com/users/fd0","html_url":"https://github.com/fd0","followers_url":"https://api.github.com/users/fd0/followers","following_url":"https://api.github.com/users/fd0/following{/other_user}","gists_url":"https://api.github.com/users/fd0/gists{/gist_id}","starred_url":"https://api.github.com/users/fd0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fd0/subscriptions","organizations_url":"https://api.github.com/users/fd0/orgs","repos_url":"https://api.github.com/users/fd0/repos","events_url":"https://api.github.com/users/fd0/events{/privacy}","received_events_url":"https://api.github.com/users/fd0/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-05-09T12:48:19Z","updated_at":"2015-05-17T23:10:51Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/restic/restic/pulls/179","html_url":"https://github.com/restic/restic/pull/179","diff_url":"https://github.com/restic/restic/pull/179.diff","patch_url":"https://github.com/restic/restic/pull/179.patch"},"body":"This is an example on how integration tests can be run with the Go testing framework. In order to run this test, run the following command in `cmd/restic`:\n\n    $ go test -v -tags integration -test.datafile ../../testsuite/fake-data.tar.gz\n\nSample output:\n\n    $ go test -v -tags integration -test.datafile ../../testsuite/fake-data.tar.gz\n    === RUN TestBackup-4                                                           \n    created restic backend 558fe89396 at /tmp/restic-test-358226688/repo\n    Please note that knowledge of your password is required to access the repository.\n    Losing your password means that your data is irrecoverably lost.\n    scan [/tmp/restic-test-358226688/testdata]\n    scanned 14 directories, 1224 files in 0:00\n    [0:00] 100.00%  0B/s  19.074 MiB / 19.074 MiB  1239 / 1238 items  0 errors  ETA 0:00 \n    duration: 0:00, 40.21MiB/s\n    snapshot b08fe909 saved\n    --- PASS: TestBackup-4 (2.54s)\n        integration_test.go:22: repository initialized at /tmp/restic-test-358226688/repo\n        integration_test.go:27: backing up [/tmp/restic-test-358226688/testdata]\n    PASS\n    ok      github.com/restic/restic/cmd/restic     2.549s\n\nWhat do you think? Is this the way to go for the integration tests?"},"comment":{"url":"https://api.github.com/repos/restic/restic/issues/comments/102868548","html_url":"https://github.com/restic/restic/pull/179#issuecomment-102868548","issue_url":"https://api.github.com/repos/restic/restic/issues/179","id":102868548,"user":{"login":"fd0","id":123276,"avatar_url":"https://avatars.githubusercontent.com/u/123276?v=3","gravatar_id":"","url":"https://api.github.com/users/fd0","html_url":"https://github.com/fd0","followers_url":"https://api.github.com/users/fd0/followers","following_url":"https://api.github.com/users/fd0/following{/other_user}","gists_url":"https://api.github.com/users/fd0/gists{/gist_id}","starred_url":"https://api.github.com/users/fd0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fd0/subscriptions","organizations_url":"https://api.github.com/users/fd0/orgs","repos_url":"https://api.github.com/users/fd0/repos","events_url":"https://api.github.com/users/fd0/events{/privacy}","received_events_url":"https://api.github.com/users/fd0/received_events","type":"User","site_admin":false},"created_at":"2015-05-17T23:10:51Z","updated_at":"2015-05-17T23:10:51Z","body":"I've just rebased the commits to master. Once #194 is merged, the messages about the 'orphaned' data blobs will vanish. I'll refactore the other integration tests in a bit."}}