mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-14 20:40:17 -05:00
Ensure fetchResponse.text is a string in sinon stub
This commit is contained in:
parent
46b22b30c7
commit
5e9dca7ddf
1 changed files with 2 additions and 2 deletions
|
@ -453,7 +453,7 @@ describe('LoggingManager', function () {
|
||||||
describe('when level is already set', function() {
|
describe('when level is already set', function() {
|
||||||
beforeEach(async function() {
|
beforeEach(async function() {
|
||||||
this.bunyanLogger.level.returns(10)
|
this.bunyanLogger.level.returns(10)
|
||||||
this.fetchResponse.text = sinon.stub().resolves(this.start + 1000)
|
this.fetchResponse.text = sinon.stub().resolves((this.start + 1000).toString())
|
||||||
this.logger.getTracingEndTime = this.logger.getTracingEndTimeMetadata
|
this.logger.getTracingEndTime = this.logger.getTracingEndTimeMetadata
|
||||||
|
|
||||||
await this.logger.checkLogLevel()
|
await this.logger.checkLogLevel()
|
||||||
|
@ -469,7 +469,7 @@ describe('LoggingManager', function () {
|
||||||
describe('when level is not already set', function() {
|
describe('when level is not already set', function() {
|
||||||
beforeEach(async function() {
|
beforeEach(async function() {
|
||||||
this.bunyanLogger.level.returns(20)
|
this.bunyanLogger.level.returns(20)
|
||||||
this.fetchResponse.text = sinon.stub().resolves(this.start + 1000)
|
this.fetchResponse.text = sinon.stub().resolves((this.start + 1000).toString())
|
||||||
this.Fetch.fetch = sinon.stub().resolves(this.fetchResponse)
|
this.Fetch.fetch = sinon.stub().resolves(this.fetchResponse)
|
||||||
this.logger.getTracingEndTime = this.logger.getTracingEndTimeMetadata
|
this.logger.getTracingEndTime = this.logger.getTracingEndTimeMetadata
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue