OXYGENHUB
# 991516a107fa oxygenhub-vscode / .flow / pipeline.kdl
1.3 KiB · last changed A test report and coverage on every push: npm run test:ci writes JUnit and LCOV of src/ through source maps, kept as the check job's junit and coverage artifacts (closes #6) 10 days ago source blame history raw
1
// oxygenhub-vscode's pipeline (OxygenFlow, docs in the oxygenflow repository):
2
// typecheck, bundle, tests and packaging, offline in a Firecracker microVM on
3
// Earth for every push. The hub client tests need a hub binary and skip here.
4
schema-version 1
5
6
// The OxygenFlow build image (oxygenflow/images/rust), with an npm cache of
7
// this repository's package-lock.json. Rebuild and re-pin it when that changes.
8
sandbox "node" {
9
    runtime "microvm"
10
    rootfs "cas://blob/85c744e509d45118942a8ca77408d56894bf7833fa806d20d08511cc90bc5024"
11
    memory-limit "2GiB"
12
    cpu-limit 2
13
    network "loopback"
14
}
15
16
job "check" {
17
    sandbox "node"
18
    exec "sh" "-euc" "npm ci --offline --cache /opt/npm-cache --no-audit --no-fund && npm run typecheck && npm run build && npm run test:ci"
19
    // A JUnit report (kept whether or not the tests pass) and line coverage
20
    // of src/ through esbuild's source maps, for the hub's Tests and
21
    // Coverage tabs.
22
    output {
23
        artifact "junit" {
24
            path "/src/out/junit.xml"
25
            when "always"
26
        }
27
        artifact "coverage" {
28
            path "/src/out/lcov.info"
29
        }
30
    }
31
}
32
33
job "package" {
34
    sandbox "node"
35
    depends-on "check"
36
    exec "sh" "-euc" "npm ci --offline --cache /opt/npm-cache --no-audit --no-fund && npm run package"
37
}