()
| 81 | }; |
| 82 | |
| 83 | const doneYet = function () { |
| 84 | messages++; |
| 85 | |
| 86 | if (messages === 1) { |
| 87 | testUser1 |
| 88 | .subscribe(function () { |
| 89 | done('testUser1 should not receive any messages'); |
| 90 | }) |
| 91 | .then(function () { |
| 92 | done('testUser1 should not authenticate successfully'); |
| 93 | }, doneYet); |
| 94 | } |
| 95 | |
| 96 | if (messages === 2) done(); |
| 97 | }; |
| 98 | |
| 99 | testUser2.subscribe(doneYet).then(function () { |
| 100 | testUser2.addActivity(activity, httpCallback); |