{"action":"created","issue":{"url":"https://api.github.com/repos/angular/protractor/issues/3045","repository_url":"https://api.github.com/repos/angular/protractor","labels_url":"https://api.github.com/repos/angular/protractor/issues/3045/labels{/name}","comments_url":"https://api.github.com/repos/angular/protractor/issues/3045/comments","events_url":"https://api.github.com/repos/angular/protractor/issues/3045/events","html_url":"https://github.com/angular/protractor/issues/3045","id":142286094,"number":3045,"title":"Test is passing without running when putting \".only\" on \"it\"","user":{"login":"benbracha","id":3404050,"avatar_url":"https://avatars.githubusercontent.com/u/3404050?v=3","gravatar_id":"","url":"https://api.github.com/users/benbracha","html_url":"https://github.com/benbracha","followers_url":"https://api.github.com/users/benbracha/followers","following_url":"https://api.github.com/users/benbracha/following{/other_user}","gists_url":"https://api.github.com/users/benbracha/gists{/gist_id}","starred_url":"https://api.github.com/users/benbracha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benbracha/subscriptions","organizations_url":"https://api.github.com/users/benbracha/orgs","repos_url":"https://api.github.com/users/benbracha/repos","events_url":"https://api.github.com/users/benbracha/events{/privacy}","received_events_url":"https://api.github.com/users/benbracha/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/angular/protractor/labels/status:%20needs%20more%20info","name":"status: needs more info","color":"bfd4f2"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":20,"created_at":"2016-03-21T08:38:55Z","updated_at":"2016-06-22T13:04:04Z","closed_at":null,"body":"Hey,\r\n\r\nSince mocha 2.4.1 it seems like test code doesn't wait for page to sync anymore.\r\nMeaning, this was working in the past:\r\n\r\n    it.only('mocha test', function() {\r\n            var addAppBtn = $('[debugId=\"create-new-app-btn\"]');\r\n            addAppBtn.click();      \r\n\r\n            console.log('HERE'); \r\n     });\r\n\r\nBut since mocha 2.4.1 the click doesn't happen, and test is passed (console log is shown).\r\n\r\nSince mocha 2.4.1 we must use callbacks on the promises, which make tests writing a lot harder and complicated:\r\n\r\n    it.only('mocha test', function(done) {\r\n          var addAppBtn = $('[debugId=\"create-new-app-btn\"]');\r\n          addAppBtn.click().then(function() {\r\n               // Do something\r\n               done();\r\n           }\r\n    });\r\n\r\nI opened an issue for mocha, but I think it should get some help / attention:\r\nhttps://github.com/mochajs/mocha/issues/2157\r\n\r\nThanks\r\n\r\nBug report\r\n---\r\n- Node Version: 0.10.29\r\n- Protractor Version: 1.5.0\r\n- Browser(s): Chrome 49\r\n- Operating System and Version OS X 10.11.1\r\n"},"comment":{"url":"https://api.github.com/repos/angular/protractor/issues/comments/227736433","html_url":"https://github.com/angular/protractor/issues/3045#issuecomment-227736433","issue_url":"https://api.github.com/repos/angular/protractor/issues/3045","id":227736433,"user":{"login":"benbracha","id":3404050,"avatar_url":"https://avatars.githubusercontent.com/u/3404050?v=3","gravatar_id":"","url":"https://api.github.com/users/benbracha","html_url":"https://github.com/benbracha","followers_url":"https://api.github.com/users/benbracha/followers","following_url":"https://api.github.com/users/benbracha/following{/other_user}","gists_url":"https://api.github.com/users/benbracha/gists{/gist_id}","starred_url":"https://api.github.com/users/benbracha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benbracha/subscriptions","organizations_url":"https://api.github.com/users/benbracha/orgs","repos_url":"https://api.github.com/users/benbracha/repos","events_url":"https://api.github.com/users/benbracha/events{/privacy}","received_events_url":"https://api.github.com/users/benbracha/received_events","type":"User","site_admin":false},"created_at":"2016-06-22T13:04:04Z","updated_at":"2016-06-22T13:04:04Z","body":"Thanks @noisette44  for the followup. I hope protractor guys will pick that soon.."}}
{"actor":{"display_login":"benbracha"}}