Savepoint
This commit is contained in:
parent
7db1a3456b
commit
02c483950c
45 changed files with 5136 additions and 256 deletions
22
tests/api.js
Normal file
22
tests/api.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
#!/usr/bin/env node
|
||||
import "dotenv/config"; // Load Envars
|
||||
import Qualiteer from "qualiteer";
|
||||
import axios from "axios";
|
||||
|
||||
// Start server
|
||||
const qltr = new Qualiteer();
|
||||
await qltr.start();
|
||||
|
||||
const url = "https://Qualiteer.elijahparker3.repl.co";
|
||||
|
||||
const testsUrl = "/api/catalog/tests";
|
||||
const resultsUrl = "/api/results/failing";
|
||||
|
||||
const get = (...args) => axios.get(`${url}/${args[0]}`, args[1]);
|
||||
|
||||
var res = await get(resultsUrl);
|
||||
console.log(res.data);
|
||||
|
||||
res = await get(resultsUrl, { headers: { count: true } });
|
||||
|
||||
console.log(res.data);
|
|
@ -11,7 +11,11 @@ const url = "https://Qualiteer.elijahparker3.repl.co";
|
|||
|
||||
// Create an initiator and make a job request
|
||||
const primary = new Initiator(url);
|
||||
const job = { command: ["node", "dev/other.js"], name: "testing", image: "node" };
|
||||
const job = {
|
||||
command: ["node", "dev/other.js"],
|
||||
name: "testing",
|
||||
image: "node",
|
||||
};
|
||||
await primary.newJob(job, null, () => console.log("Primary Job Concluded"));
|
||||
|
||||
/*const { clients } = qltr.jobs;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue