Skip to content

Commit

Permalink
Update unit tests for api_anonymous, return empty with http/200 inste…
Browse files Browse the repository at this point in the history
…ad of http/404
  • Loading branch information
xbgmsharp committed Sep 4, 2024
1 parent fe950b2 commit dc79ca2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/index5.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ var moment = require("moment");
.set(test.logs.header.name, test.logs.header.value)
.set("Accept", "application/json")
.end(function (err, res) {
res.status.should.equal(404);
res.status.should.equal(200);
should.exist(res.header["content-type"]);
should.exist(res.header["server"]);
res.header["content-type"].should.match(new RegExp("json", "g"));
Expand Down Expand Up @@ -192,7 +192,7 @@ var moment = require("moment");
.set("Accept", "application/json")
.end(function (err, res) {
console.log(res.text);
res.status.should.equal(404); // return 404 as it is not enable in user settings.
res.status.should.equal(200); // return 404 as it is not enable in user settings.
should.exist(res.header["content-type"]);
should.exist(res.header["server"]);
res.header["content-type"].should.match(new RegExp("json", "g"));
Expand Down

0 comments on commit dc79ca2

Please sign in to comment.