{"action":"opened","issue":{"url":"https://api.github.com/repos/angular/protractor/issues/2623","labels_url":"https://api.github.com/repos/angular/protractor/issues/2623/labels{/name}","comments_url":"https://api.github.com/repos/angular/protractor/issues/2623/comments","events_url":"https://api.github.com/repos/angular/protractor/issues/2623/events","html_url":"https://github.com/angular/protractor/issues/2623","id":112420754,"number":2623,"title":"Object has no method 'toEqual' ","user":{"login":"smartdevj","id":14880744,"avatar_url":"https://avatars.githubusercontent.com/u/14880744?v=3","gravatar_id":"","url":"https://api.github.com/users/smartdevj","html_url":"https://github.com/smartdevj","followers_url":"https://api.github.com/users/smartdevj/followers","following_url":"https://api.github.com/users/smartdevj/following{/other_user}","gists_url":"https://api.github.com/users/smartdevj/gists{/gist_id}","starred_url":"https://api.github.com/users/smartdevj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smartdevj/subscriptions","organizations_url":"https://api.github.com/users/smartdevj/orgs","repos_url":"https://api.github.com/users/smartdevj/repos","events_url":"https://api.github.com/users/smartdevj/events{/privacy}","received_events_url":"https://api.github.com/users/smartdevj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-20T17:35:51Z","updated_at":"2015-10-20T17:35:51Z","closed_at":null,"body":"Below is the following code that gets the text of the element and tries to compare it \r\n\r\n element(by.css('a[href*=\"/resources\"]')).getWebElement().then(function () {\r\n            ResourcesTitle = element(by.css('a[href*=\"/resources\"]')).getText();\r\n            console.log(ResourcesTitle);\r\n        });\r\n  element(by.css('a[href*=\"/resources\"]')).isPresent().then(function () {\r\n            console.log('>>>>>>Text is in English');\r\n            expect(ResourcesTitle.getText()).toEqual('Resources');\r\n\r\n\r\nI get an error: TypeError: Object #<Assertion> has no method 'toEqual'"}}