Skip to content

Commit 5655a7f

Browse files
committed
Restore removed tests
1 parent 9b33ac1 commit 5655a7f

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

packages/dd-trace/test/crashtracking/crashtracker.spec.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,21 @@ describeNotWindows('crashtracker', () => {
5555
sinon.assert.notCalled(log.error)
5656
})
5757

58+
it('should initialize the binding only once', () => {
59+
crashtracker.start(config)
60+
crashtracker.start(config)
61+
62+
sinon.assert.calledOnce(binding.init)
63+
})
64+
65+
it('should reconfigure when started multiple times', () => {
66+
crashtracker.start(config)
67+
crashtracker.start(config)
68+
69+
sinon.assert.called(binding.updateConfig)
70+
sinon.assert.called(binding.updateMetadata)
71+
})
72+
5873
it('should handle errors', () => {
5974
crashtracker.start(null)
6075

0 commit comments

Comments
 (0)