{"action":"created","comment":{"url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/comments/32370929","id":32370929,"diff_hunk":"@@ -0,0 +1,116 @@\n+import Ember from 'ember';\n+import { module, test } from 'qunit';\n+import startApp from '../helpers/start-app';\n+\n+var application;\n+var originalConfirm;\n+var confirmCalledWith;\n+\n+function defineFixturesFor(name, fixtures) {\n+  var modelClass = application.__container__.lookupFactory('model:' + name);\n+  modelClass.FIXTURES = fixtures;\n+}\n+\n+module('Acceptance: Product', {\n+  beforeEach: function() {\n+    application = startApp();\n+    defineFixturesFor('product', []);\n+    originalConfirm = window.confirm;\n+    window.confirm = function() {\n+      confirmCalledWith = [].slice.call(arguments);\n+      return true;\n+    };\n+  },\n+  afterEach: function() {\n+    Ember.run(application, 'destroy');\n+    window.confirm = originalConfirm;\n+    confirmCalledWith = null;\n+  }\n+});\n+\n+test('visiting /products without data', function(assert) {\n+  visit('/products');\n+\n+  andThen(function() {\n+    assert.equal(currentPath(), 'products.index');\n+    assert.equal(find('#blankslate').text().trim(), 'No Products found');\n+  });\n+});\n+\n+test('visiting /products with data', function(assert) {\n+  defineFixturesFor('product', [{ id: 1, name: 'MyString', price: 42, description: 'MyString' }]);\n+  visit('/products');\n+\n+  andThen(function() {\n+    assert.equal(currentPath(), 'products.index');\n+    assert.equal(find('#blankslate').length, 0);\n+    assert.equal(find('table tbody tr').length, 1);\n+  });\n+});\n+\n+test('create a new product', function(assert) {\n+  visit('/products');\n+  click('a:contains(New Product)');\n+\n+  andThen(function() {\n+    assert.equal(currentPath(), 'products.new');\n+\n+    fillIn('label:contains(Name) input', 'MyString');\n+    fillIn('label:contains(Price) input', 42);\n+    fillIn('label:contains(Description) input', 'MyString');\n+\n+    click('input:submit');\n+  });\n+\n+  andThen(function() {\n+    assert.equal(find('#blankslate').length, 0);\n+    assert.equal(find('table tbody tr').length, 1);\n+  });\n+});\n+\n+test('update an existing product', function(assert) {\n+  defineFixturesFor('product', [{ id: 1 }]);\n+  visit('/products');\n+  click('a:contains(Edit)');\n+\n+  andThen(function() {\n+    assert.equal(currentPath(), 'products.edit');\n+\n+    fillIn('label:contains(Name) input', 'MyString');\n+    fillIn('label:contains(Price) input', 42);\n+    fillIn('label:contains(Description) input', 'MyString');\n+\n+    click('input:submit');\n+  });\n+\n+  andThen(function() {\n+    assert.equal(find('#blankslate').length, 0);\n+    assert.equal(find('table tbody tr').length, 1);\n+  });\n+});\n+\n+test('show an existing product', function(assert) {\n+  defineFixturesFor('product', [{ id: 1, name: 'MyString', price: 42, description: 'MyString' }]);\n+  visit('/products');","path":"tests/acceptance/products-test.js","position":94,"original_position":94,"commit_id":"57ab25a50fcaa40d7082987c9a118901724ef2a3","original_commit_id":"57ab25a50fcaa40d7082987c9a118901724ef2a3","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"'visit' is not defined.","created_at":"2015-06-13T14:33:51Z","updated_at":"2015-06-13T14:33:51Z","html_url":"https://github.com/jyolewis/dealer_demo/pull/12#discussion_r32370929","pull_request_url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12","_links":{"self":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/comments/32370929"},"html":{"href":"https://github.com/jyolewis/dealer_demo/pull/12#discussion_r32370929"},"pull_request":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12"}}},"pull_request":{"url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12","id":37625739,"html_url":"https://github.com/jyolewis/dealer_demo/pull/12","diff_url":"https://github.com/jyolewis/dealer_demo/pull/12.diff","patch_url":"https://github.com/jyolewis/dealer_demo/pull/12.patch","issue_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues/12","number":12,"state":"open","locked":false,"title":"Allows product creation UI","user":{"login":"jyolewis","id":8296574,"avatar_url":"https://avatars.githubusercontent.com/u/8296574?v=3","gravatar_id":"","url":"https://api.github.com/users/jyolewis","html_url":"https://github.com/jyolewis","followers_url":"https://api.github.com/users/jyolewis/followers","following_url":"https://api.github.com/users/jyolewis/following{/other_user}","gists_url":"https://api.github.com/users/jyolewis/gists{/gist_id}","starred_url":"https://api.github.com/users/jyolewis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jyolewis/subscriptions","organizations_url":"https://api.github.com/users/jyolewis/orgs","repos_url":"https://api.github.com/users/jyolewis/repos","events_url":"https://api.github.com/users/jyolewis/events{/privacy}","received_events_url":"https://api.github.com/users/jyolewis/received_events","type":"User","site_admin":false},"body":"…aying a product backed with rails DB","created_at":"2015-06-13T14:33:36Z","updated_at":"2015-06-13T14:33:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5be414891ba225284658490885ebdda7bd6d50b3","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12/commits","review_comments_url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12/comments","review_comment_url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues/12/comments","statuses_url":"https://api.github.com/repos/jyolewis/dealer_demo/statuses/57ab25a50fcaa40d7082987c9a118901724ef2a3","head":{"label":"jyolewis:jl_user","ref":"jl_user","sha":"57ab25a50fcaa40d7082987c9a118901724ef2a3","user":{"login":"jyolewis","id":8296574,"avatar_url":"https://avatars.githubusercontent.com/u/8296574?v=3","gravatar_id":"","url":"https://api.github.com/users/jyolewis","html_url":"https://github.com/jyolewis","followers_url":"https://api.github.com/users/jyolewis/followers","following_url":"https://api.github.com/users/jyolewis/following{/other_user}","gists_url":"https://api.github.com/users/jyolewis/gists{/gist_id}","starred_url":"https://api.github.com/users/jyolewis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jyolewis/subscriptions","organizations_url":"https://api.github.com/users/jyolewis/orgs","repos_url":"https://api.github.com/users/jyolewis/repos","events_url":"https://api.github.com/users/jyolewis/events{/privacy}","received_events_url":"https://api.github.com/users/jyolewis/received_events","type":"User","site_admin":false},"repo":{"id":36298765,"name":"dealer_demo","full_name":"jyolewis/dealer_demo","owner":{"login":"jyolewis","id":8296574,"avatar_url":"https://avatars.githubusercontent.com/u/8296574?v=3","gravatar_id":"","url":"https://api.github.com/users/jyolewis","html_url":"https://github.com/jyolewis","followers_url":"https://api.github.com/users/jyolewis/followers","following_url":"https://api.github.com/users/jyolewis/following{/other_user}","gists_url":"https://api.github.com/users/jyolewis/gists{/gist_id}","starred_url":"https://api.github.com/users/jyolewis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jyolewis/subscriptions","organizations_url":"https://api.github.com/users/jyolewis/orgs","repos_url":"https://api.github.com/users/jyolewis/repos","events_url":"https://api.github.com/users/jyolewis/events{/privacy}","received_events_url":"https://api.github.com/users/jyolewis/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jyolewis/dealer_demo","description":"car dealer site using emberjs and rails","fork":false,"url":"https://api.github.com/repos/jyolewis/dealer_demo","forks_url":"https://api.github.com/repos/jyolewis/dealer_demo/forks","keys_url":"https://api.github.com/repos/jyolewis/dealer_demo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jyolewis/dealer_demo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jyolewis/dealer_demo/teams","hooks_url":"https://api.github.com/repos/jyolewis/dealer_demo/hooks","issue_events_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues/events{/number}","events_url":"https://api.github.com/repos/jyolewis/dealer_demo/events","assignees_url":"https://api.github.com/repos/jyolewis/dealer_demo/assignees{/user}","branches_url":"https://api.github.com/repos/jyolewis/dealer_demo/branches{/branch}","tags_url":"https://api.github.com/repos/jyolewis/dealer_demo/tags","blobs_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/refs{/sha}","trees_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jyolewis/dealer_demo/statuses/{sha}","languages_url":"https://api.github.com/repos/jyolewis/dealer_demo/languages","stargazers_url":"https://api.github.com/repos/jyolewis/dealer_demo/stargazers","contributors_url":"https://api.github.com/repos/jyolewis/dealer_demo/contributors","subscribers_url":"https://api.github.com/repos/jyolewis/dealer_demo/subscribers","subscription_url":"https://api.github.com/repos/jyolewis/dealer_demo/subscription","commits_url":"https://api.github.com/repos/jyolewis/dealer_demo/commits{/sha}","git_commits_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/commits{/sha}","comments_url":"https://api.github.com/repos/jyolewis/dealer_demo/comments{/number}","issue_comment_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues/comments{/number}","contents_url":"https://api.github.com/repos/jyolewis/dealer_demo/contents/{+path}","compare_url":"https://api.github.com/repos/jyolewis/dealer_demo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jyolewis/dealer_demo/merges","archive_url":"https://api.github.com/repos/jyolewis/dealer_demo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jyolewis/dealer_demo/downloads","issues_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues{/number}","pulls_url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls{/number}","milestones_url":"https://api.github.com/repos/jyolewis/dealer_demo/milestones{/number}","notifications_url":"https://api.github.com/repos/jyolewis/dealer_demo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jyolewis/dealer_demo/labels{/name}","releases_url":"https://api.github.com/repos/jyolewis/dealer_demo/releases{/id}","created_at":"2015-05-26T13:46:26Z","updated_at":"2015-06-04T16:57:27Z","pushed_at":"2015-06-13T14:33:36Z","git_url":"git://github.com/jyolewis/dealer_demo.git","ssh_url":"git@github.com:jyolewis/dealer_demo.git","clone_url":"https://github.com/jyolewis/dealer_demo.git","svn_url":"https://github.com/jyolewis/dealer_demo","homepage":"","size":616,"stargazers_count":0,"watchers_count":0,"language":"Handlebars","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":6,"forks":0,"open_issues":6,"watchers":0,"default_branch":"master"}},"base":{"label":"jyolewis:master","ref":"master","sha":"2ea68b2059aa285f81f36c7c7cf987bed54a19c3","user":{"login":"jyolewis","id":8296574,"avatar_url":"https://avatars.githubusercontent.com/u/8296574?v=3","gravatar_id":"","url":"https://api.github.com/users/jyolewis","html_url":"https://github.com/jyolewis","followers_url":"https://api.github.com/users/jyolewis/followers","following_url":"https://api.github.com/users/jyolewis/following{/other_user}","gists_url":"https://api.github.com/users/jyolewis/gists{/gist_id}","starred_url":"https://api.github.com/users/jyolewis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jyolewis/subscriptions","organizations_url":"https://api.github.com/users/jyolewis/orgs","repos_url":"https://api.github.com/users/jyolewis/repos","events_url":"https://api.github.com/users/jyolewis/events{/privacy}","received_events_url":"https://api.github.com/users/jyolewis/received_events","type":"User","site_admin":false},"repo":{"id":36298765,"name":"dealer_demo","full_name":"jyolewis/dealer_demo","owner":{"login":"jyolewis","id":8296574,"avatar_url":"https://avatars.githubusercontent.com/u/8296574?v=3","gravatar_id":"","url":"https://api.github.com/users/jyolewis","html_url":"https://github.com/jyolewis","followers_url":"https://api.github.com/users/jyolewis/followers","following_url":"https://api.github.com/users/jyolewis/following{/other_user}","gists_url":"https://api.github.com/users/jyolewis/gists{/gist_id}","starred_url":"https://api.github.com/users/jyolewis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jyolewis/subscriptions","organizations_url":"https://api.github.com/users/jyolewis/orgs","repos_url":"https://api.github.com/users/jyolewis/repos","events_url":"https://api.github.com/users/jyolewis/events{/privacy}","received_events_url":"https://api.github.com/users/jyolewis/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jyolewis/dealer_demo","description":"car dealer site using emberjs and rails","fork":false,"url":"https://api.github.com/repos/jyolewis/dealer_demo","forks_url":"https://api.github.com/repos/jyolewis/dealer_demo/forks","keys_url":"https://api.github.com/repos/jyolewis/dealer_demo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jyolewis/dealer_demo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jyolewis/dealer_demo/teams","hooks_url":"https://api.github.com/repos/jyolewis/dealer_demo/hooks","issue_events_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues/events{/number}","events_url":"https://api.github.com/repos/jyolewis/dealer_demo/events","assignees_url":"https://api.github.com/repos/jyolewis/dealer_demo/assignees{/user}","branches_url":"https://api.github.com/repos/jyolewis/dealer_demo/branches{/branch}","tags_url":"https://api.github.com/repos/jyolewis/dealer_demo/tags","blobs_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/refs{/sha}","trees_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jyolewis/dealer_demo/statuses/{sha}","languages_url":"https://api.github.com/repos/jyolewis/dealer_demo/languages","stargazers_url":"https://api.github.com/repos/jyolewis/dealer_demo/stargazers","contributors_url":"https://api.github.com/repos/jyolewis/dealer_demo/contributors","subscribers_url":"https://api.github.com/repos/jyolewis/dealer_demo/subscribers","subscription_url":"https://api.github.com/repos/jyolewis/dealer_demo/subscription","commits_url":"https://api.github.com/repos/jyolewis/dealer_demo/commits{/sha}","git_commits_url":"https://api.github.com/repos/jyolewis/dealer_demo/git/commits{/sha}","comments_url":"https://api.github.com/repos/jyolewis/dealer_demo/comments{/number}","issue_comment_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues/comments{/number}","contents_url":"https://api.github.com/repos/jyolewis/dealer_demo/contents/{+path}","compare_url":"https://api.github.com/repos/jyolewis/dealer_demo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jyolewis/dealer_demo/merges","archive_url":"https://api.github.com/repos/jyolewis/dealer_demo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jyolewis/dealer_demo/downloads","issues_url":"https://api.github.com/repos/jyolewis/dealer_demo/issues{/number}","pulls_url":"https://api.github.com/repos/jyolewis/dealer_demo/pulls{/number}","milestones_url":"https://api.github.com/repos/jyolewis/dealer_demo/milestones{/number}","notifications_url":"https://api.github.com/repos/jyolewis/dealer_demo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jyolewis/dealer_demo/labels{/name}","releases_url":"https://api.github.com/repos/jyolewis/dealer_demo/releases{/id}","created_at":"2015-05-26T13:46:26Z","updated_at":"2015-06-04T16:57:27Z","pushed_at":"2015-06-13T14:33:36Z","git_url":"git://github.com/jyolewis/dealer_demo.git","ssh_url":"git@github.com:jyolewis/dealer_demo.git","clone_url":"https://github.com/jyolewis/dealer_demo.git","svn_url":"https://github.com/jyolewis/dealer_demo","homepage":"","size":616,"stargazers_count":0,"watchers_count":0,"language":"Handlebars","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":6,"forks":0,"open_issues":6,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12"},"html":{"href":"https://github.com/jyolewis/dealer_demo/pull/12"},"issue":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/issues/12"},"comments":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/issues/12/comments"},"review_comments":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12/comments"},"review_comment":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/pulls/12/commits"},"statuses":{"href":"https://api.github.com/repos/jyolewis/dealer_demo/statuses/57ab25a50fcaa40d7082987c9a118901724ef2a3"}}}}