mirror of
https://github.com/msojocs/wx-compiler.git
synced 2025-07-19 00:00:04 +08:00
feat: ci for module
This commit is contained in:
parent
c75bbaa754
commit
fbe206ff73
4
.github/workflows/release.yml
vendored
4
.github/workflows/release.yml
vendored
@ -9,7 +9,7 @@ on:
|
|||||||
push:
|
push:
|
||||||
tags:
|
tags:
|
||||||
- v*
|
- v*
|
||||||
branches: [ master, dev, ci]
|
branches: [ master, dev, ci, module]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ master ]
|
branches: [ master ]
|
||||||
# # Allows you to run this workflow manually from the Actions tab
|
# # Allows you to run this workflow manually from the Actions tab
|
||||||
@ -66,7 +66,7 @@ jobs:
|
|||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
ls -l build
|
ls -l build
|
||||||
mkdir -p tmp/build
|
mkdir -p tmp/build
|
||||||
mv build/{wcc,wcsc} tmp/build
|
mv build/{wcc,wcsc,wcc_module.node} tmp/build
|
||||||
cd tmp/build
|
cd tmp/build
|
||||||
ls -l
|
ls -l
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@ module.exports = {
|
|||||||
'ts-node/register'
|
'ts-node/register'
|
||||||
],
|
],
|
||||||
recursive: true,
|
recursive: true,
|
||||||
// spec: "./test/spec/**/*.spec.ts",
|
spec: "./test/spec/**/*.spec.ts",
|
||||||
spec: "test/spec/wcc/module/module.spec.ts",
|
// spec: "test/spec/wcc/module/module.spec.ts",
|
||||||
timeout: 20000,
|
timeout: 20000,
|
||||||
}
|
}
|
@ -9,5 +9,7 @@ cd build
|
|||||||
cmake ..
|
cmake ..
|
||||||
cmake --build . --config Release --target wcc
|
cmake --build . --config Release --target wcc
|
||||||
cmake --build . --config Release --target wcsc
|
cmake --build . --config Release --target wcsc
|
||||||
|
cmake --build . --config Release --target wcc_module
|
||||||
readelf -s ./wcc | grep -oP "GLIBC.*" | sort | uniq
|
readelf -s ./wcc | grep -oP "GLIBC.*" | sort | uniq
|
||||||
readelf -s ./wcsc | grep -oP "GLIBC.*" | sort | uniq
|
readelf -s ./wcsc | grep -oP "GLIBC.*" | sort | uniq
|
||||||
|
readelf -s ./wcc_module.node | grep -oP "GLIBC.*" | sort | uniq
|
@ -2,6 +2,7 @@ import * as fs from 'fs'
|
|||||||
import { request } from "http";
|
import { request } from "http";
|
||||||
import { CompilerOptions } from './types';
|
import { CompilerOptions } from './types';
|
||||||
import path from 'path'
|
import path from 'path'
|
||||||
|
import { execFileSync } from 'child_process';
|
||||||
|
|
||||||
// 预先启动wine focker环境,再使用HTTP协议,最后销毁容器
|
// 预先启动wine focker环境,再使用HTTP协议,最后销毁容器
|
||||||
const HTTP = {
|
const HTTP = {
|
||||||
@ -68,5 +69,11 @@ const wccNative = async (optionsPath: string) => {
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
wcsc: wcscNative,
|
wcsc: wcscNative,
|
||||||
wcc: wccNative
|
wcc: wccNative,
|
||||||
|
start: () => {
|
||||||
|
execFileSync(path.resolve(__dirname, './nwjs/wine-prepare.sh'), { stdio: 'inherit' })
|
||||||
|
},
|
||||||
|
close: () => {
|
||||||
|
request('http://localhost:8083/close').end()
|
||||||
|
}
|
||||||
}
|
}
|
@ -5,11 +5,13 @@ import path from 'path';
|
|||||||
import linux from '../../../runner/module-linux'
|
import linux from '../../../runner/module-linux'
|
||||||
import windows from '../../../runner/module-windows'
|
import windows from '../../../runner/module-windows'
|
||||||
import * as fs from 'fs'
|
import * as fs from 'fs'
|
||||||
import { execFileSync } from 'child_process';
|
|
||||||
|
|
||||||
describe("wcc - module", function () {
|
describe("wcc - module", function () {
|
||||||
this.beforeAll(() => {
|
this.beforeAll(() => {
|
||||||
// execFileSync(path.resolve(__dirname, '../../../runner/nwjs/wine-prepare.sh'), { stdio: 'inherit' })
|
windows.start()
|
||||||
|
})
|
||||||
|
this.afterAll(() => {
|
||||||
|
windows.close()
|
||||||
})
|
})
|
||||||
describe("llw: linux output should deep equal with wine", function () {
|
describe("llw: linux output should deep equal with wine", function () {
|
||||||
// afterEach(function(){
|
// afterEach(function(){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user