Skip to content

skill issue - #149

Open
Volas171 wants to merge 1 commit into
masterfrom
Volas171-patch-1
Open

skill issue#149
Volas171 wants to merge 1 commit into
masterfrom
Volas171-patch-1

Conversation

@Volas171

Copy link
Copy Markdown
Collaborator

No description provided.

@Volas171
Volas171 enabled auto-merge November 3, 2024 01:42
@Volas171Volas171 self-assigned this Nov 3, 2024
@sonarqubecloud

Copy link
Copy Markdown

@Volas171
Volas171 requested review from Itzbenz and removed request for ItzbenzNovember 3, 2024 01:43
@github-actions

Copy link
Copy Markdown
Contributor

Coverage report

Caution

Test run failed

St.
CategoryPercentageCovered / Total
🟡Statements
63.56% (+0.55% 🔼)
464/730
🔴Branches
46.15% (+0.89% 🔼)
156/338
🟡Functions67.78%61/90
🟡Lines
64.69% (+0.58% 🔼)
447/691

Test suite run failed

Failed tests: 11/20. Failed suites: 1/2.
 ● v3 Static API Test › GET /api/v3/health
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
26 |
27 | describe("v3 Static API Test", () => {
> 28 | test("GET /api/v3/health", async () => {
| ^
29 | return request.get("/api/v3/health").expect(200);
30 | });
31 | test("GET /api/v3/meta/categories", async () => {
at test (test/v3.test.js:28:5)
at Object.describe (test/v3.test.js:27:1)
● v3 Classification API Test › GET /api/v3/classification/https://cdn.discordapp.com/attachments/997389718163566652/1000542968052207708/unknown.png
expected 200 "OK", got 404 "Not Found"
48 | test("GET /api/v3/classification/" + url, async () => {
49 | return await request.get("/api/v3/classification/" + encodeURIComponent(url))
> 50 | .expect(200)
| ^
51 | .expect('Content-Type', /json/)
52 | .expect((res) => {
53 | expect(res.body.data.data).toBeDefined();
at Object.expect (test/v3.test.js:50:18)
----
at Test._assertStatus (node_modules/supertest/lib/test.js:252:14)
at node_modules/supertest/lib/test.js:308:13
at Test._assertFunction (node_modules/supertest/lib/test.js:285:13)
at Test.assert (node_modules/supertest/lib/test.js:164:23)
at localAssert (node_modules/supertest/lib/test.js:120:14)
at node_modules/supertest/lib/test.js:125:7
at Test.fn [as callback] (node_modules/superagent/src/node/index.js:925:3)
at callback (node_modules/superagent/src/node/index.js:1166:18)
at IncomingMessage.fn (node_modules/superagent/src/node/parsers/json.js:19:7)
● v3 Classification API Test › GET /api/v3/classification/https://github.com/o7-Fire/General/raw/master/AI/Logo/Accomplish-o7.png
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
46 | describe("v3 Classification API Test", () => {
47 | for (const url of testImageUrls) {
> 48 | test("GET /api/v3/classification/" + url, async () => {
| ^
49 | return await request.get("/api/v3/classification/" + encodeURIComponent(url))
50 | .expect(200)
51 | .expect('Content-Type', /json/)
at test (test/v3.test.js:48:9)
at Object.describe (test/v3.test.js:46:1)
● v3 Classification API Test › GET /api/v3/classification/https://picsum.photos/224
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
46 | describe("v3 Classification API Test", () => {
47 | for (const url of testImageUrls) {
> 48 | test("GET /api/v3/classification/" + url, async () => {
| ^
49 | return await request.get("/api/v3/classification/" + encodeURIComponent(url))
50 | .expect(200)
51 | .expect('Content-Type', /json/)
at test (test/v3.test.js:48:9)
at Object.describe (test/v3.test.js:46:1)
● v3 Classification API Test › GET /api/v3/classification/https://upload.wikimedia.org/wikipedia/commons/3/3e/Exploding_Wikipedia-logo.gif
expected 200 "OK", got 500 "Internal Server Error"
48 | test("GET /api/v3/classification/" + url, async () => {
49 | return await request.get("/api/v3/classification/" + encodeURIComponent(url))
> 50 | .expect(200)
| ^
51 | .expect('Content-Type', /json/)
52 | .expect((res) => {
53 | expect(res.body.data.data).toBeDefined();
at Object.expect (test/v3.test.js:50:18)
----
at Test._assertStatus (node_modules/supertest/lib/test.js:252:14)
at node_modules/supertest/lib/test.js:308:13
at Test._assertFunction (node_modules/supertest/lib/test.js:285:13)
at Test.assert (node_modules/supertest/lib/test.js:164:23)
at localAssert (node_modules/supertest/lib/test.js:120:14)
at node_modules/supertest/lib/test.js:125:7
at Test.fn [as callback] (node_modules/superagent/src/node/index.js:925:3)
at callback (node_modules/superagent/src/node/index.js:1166:18)
at IncomingMessage.fn (node_modules/superagent/src/node/parsers/json.js:19:7)
● v3 Classification API Test › GET /api/v3/classification/https://upload.wikimedia.org/wikipedia/commons/thumb/b/b6/SIPI_Jelly_Beans_4.1.07.tiff/lossy-page1-256px-SIPI_Jelly_Beans_4.1.07.tiff.jpg
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
46 | describe("v3 Classification API Test", () => {
47 | for (const url of testImageUrls) {
> 48 | test("GET /api/v3/classification/" + url, async () => {
| ^
49 | return await request.get("/api/v3/classification/" + encodeURIComponent(url))
50 | .expect(200)
51 | .expect('Content-Type', /json/)
at test (test/v3.test.js:48:9)
at Object.describe (test/v3.test.js:46:1)
● v3 Classification API Test › GET /api/v3/classification Cache Test
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
55 | });
56 | }
> 57 | test("GET /api/v3/classification Cache Test", async () => {
| ^
58 | for (let i = 0; i < 10; i++) {
59 | await request.get("/api/v3/classification/" + encodeURIComponent(NSFWModel.TEST_URL))
60 | .expect(200)
at test (test/v3.test.js:57:5)
at Object.describe (test/v3.test.js:46:1)
● v3 Classification API Test › POST /api/v3/classification
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
65 | }
66 | });
> 67 | test("POST /api/v3/classification", async () => {
| ^
68 | return request.post("/api/v3/classification").attach("file", "test/assets/1.png").expect(200);
69 | });
70 | test("POST /api/v3/classification Cache Test", async () => {
at test (test/v3.test.js:67:5)
at Object.describe (test/v3.test.js:46:1)
● v3 Classification API Test › POST /api/v3/classification Cache Test
thrown: "Exceeded timeout of 30000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
68 | return request.post("/api/v3/classification").attach("file", "test/assets/1.png").expect(200);
69 | });
> 70 | test("POST /api/v3/classification Cache Test", async () => {
| ^
71 | for (let i = 0; i < 10; i++) {
72 | await request.post("/api/v3/classification").attach("file", "test/assets/1.png").expect(200);
73 | }
at test (test/v3.test.js:70:5)
at Object.describe (test/v3.test.js:46:1)
● v3 Classification API Test › GET /api/v3/hash/:hash
expected 200 "OK", got 404 "Not Found"
77 | //TODO get hash from request above
78 | const hash = "8d311167da7ea1130a1e9983adbd034e9613f3e6e5f36fe87da811d9173374b1";
> 79 | return request.get("/api/v3/hash/" + hash).expect(200);
| ^
80 | });
81 | test("POST /api/v3/hash", async () => {
82 | return request.post("/api/v3/hash").attach("file", "test/assets/1.png").expect(200);
at Object.expect (test/v3.test.js:79:52)
----
at Test._assertStatus (node_modules/supertest/lib/test.js:252:14)
at node_modules/supertest/lib/test.js:308:13
at Test._assertFunction (node_modules/supertest/lib/test.js:285:13)
at Test.assert (node_modules/supertest/lib/test.js:164:23)
at localAssert (node_modules/supertest/lib/test.js:120:14)
at node_modules/supertest/lib/test.js:125:7
at Test.fn [as callback] (node_modules/superagent/src/node/index.js:925:3)
at callback (node_modules/superagent/src/node/index.js:1166:18)
at IncomingMessage.fn (node_modules/superagent/src/node/parsers/json.js:19:7)
● v3 Classification API Test › POST /api/v3/hash
expected 200 "OK", got 404 "Not Found"
80 | });
81 | test("POST /api/v3/hash", async () => {
> 82 | return request.post("/api/v3/hash").attach("file", "test/assets/1.png").expect(200);
| ^
83 | });
84 | });
85 |
at Object.expect (test/v3.test.js:82:81)
----
at Test._assertStatus (node_modules/supertest/lib/test.js:252:14)
at node_modules/supertest/lib/test.js:308:13
at Test._assertFunction (node_modules/supertest/lib/test.js:285:13)
at Test.assert (node_modules/supertest/lib/test.js:164:23)
at localAssert (node_modules/supertest/lib/test.js:120:14)
at node_modules/supertest/lib/test.js:125:7
at Test.fn [as callback] (node_modules/superagent/src/node/index.js:925:3)
at callback (node_modules/superagent/src/node/index.js:1166:18)
at IncomingMessage.fn (node_modules/superagent/src/node/parsers/json.js:19:7)

Report generated by 🧪jest coverage report action from af4c0f5

@Volas171

Copy link
Copy Markdown
CollaboratorAuthor

massive skill issue

@Dofuscan

Copy link
Copy Markdown

failure

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@Volas171@Dofuscan