1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Remove unnecessary assertion in e2e metrics test (#9974)

The assertion ensuring that there were at least 3 metrics received
didn't end up being useful. If this assertion fails, it doesn't explain
what segment events _were_ received.

By removing this assertion and letting the later assertions catch this
case, we at least learn which of the three expected events were
present.
This commit is contained in:
Mark Stacey 2020-12-02 17:27:42 -03:30 committed by GitHub
parent 5fb2e544d4
commit ba98edf604
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -35,10 +35,6 @@ describe('Segment metrics', function () {
await driver.findElement(By.css('[data-testid="eth-overview-send"]'))
assert.ok(segmentSpy.called, 'Segment should receive metrics')
assert.ok(
segmentSpy.callCount >= 3,
'At least 3 segment events should be sent',
)
const firstSegmentEvent = segmentSpy.getCall(0).args[0]
assert.equal(firstSegmentEvent.name, 'Home')