singularci
Version:
SingularCI is a DSL transpiler used to generate CI/CD configuration files for existing CI platforms
25 lines • 1.18 kB
JavaScript
;
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const Checkout_1 = __importDefault(require("../../../src/SemanticModel/Tasks/Checkout"));
const TaskEnum_1 = require("../../../src/SemanticModel/Tasks/TaskEnum");
let checkout;
const repoUrl = "fake-repo.remote.git";
const repoName = "FakeRepo";
beforeEach(() => {
const checkoutFactory = new Checkout_1.default();
checkout = checkoutFactory.createCheckoutTask(repoUrl, repoName);
});
test("getRepositoryURL should be able to get the repository URL", () => {
expect(checkout.getRepositoryURL()).toBe("fake-repo.remote.git");
});
test("getRepositoryName should be able to get the repository name", () => {
expect(checkout.getRepositoryName()).toBe("FakeRepo");
});
test('getType should be able to get the correct task type', () => {
const localCheckout = new Checkout_1.default().createCheckoutTask("", "");
expect(localCheckout.getType()).toBe(TaskEnum_1.TaskType.Checkout);
});
//# sourceMappingURL=Checkout.test.js.map