Initial Commit
This commit is contained in:
25
tests/unit/demo.spec.ts
Normal file
25
tests/unit/demo.spec.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
import { validateSchema } from '$lib/utils/nginx-utils';
|
||||
import { portScan } from '$lib/utils/ports-utils';
|
||||
import { describe, it, expect } from 'vitest';
|
||||
|
||||
describe('sum test', () => {
|
||||
it('adds 1 + 2 to equal 3', () => {
|
||||
expect(1 + 2).toBe(3);
|
||||
});
|
||||
});
|
||||
|
||||
describe('port gathering test', () => {
|
||||
it('gathers ports from terminal', async () => {
|
||||
const ports = await portScan()
|
||||
console.log(ports)
|
||||
expect(ports.size).not.toBe(0)
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
describe('nginx validation', () => {
|
||||
it('validates nginx configurations', async () => {
|
||||
const validation = await validateSchema()
|
||||
expect(validation).toBe(true)
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user