release actions
This commit is contained in:
parent
047174291b
commit
bce7b1cdd4
8 changed files with 182 additions and 73 deletions
11
.gitea/workflows/action_push.yml
Normal file
11
.gitea/workflows/action_push.yml
Normal file
|
@ -0,0 +1,11 @@
|
|||
name: Push Action
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- '!**'
|
||||
|
||||
jobs:
|
||||
test:
|
||||
uses: ./.gitea/workflows/test.yml
|
||||
|
16
.gitea/workflows/action_tag.yml
Normal file
16
.gitea/workflows/action_tag.yml
Normal file
|
@ -0,0 +1,16 @@
|
|||
name: Tag Action
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- v*
|
||||
|
||||
jobs:
|
||||
test:
|
||||
uses: ./.gitea/workflows/test.yml
|
||||
release_code:
|
||||
needs: test
|
||||
uses: ./.gitea/workflows/release_code.yml
|
||||
release_amd:
|
||||
needs: [test, release_code]
|
||||
uses: ./.gitea/workflows/release_amd.yml
|
36
.gitea/workflows/release_amd.yml
Normal file
36
.gitea/workflows/release_amd.yml
Normal file
|
@ -0,0 +1,36 @@
|
|||
name: Outbag AMD Release
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
secrets:
|
||||
|
||||
|
||||
jobs:
|
||||
release-amd:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Build
|
||||
run: |
|
||||
mkdir build
|
||||
npm run bundleRelease
|
||||
|
||||
- name: Build AMD
|
||||
run: |
|
||||
npm run build-amd
|
||||
mkdir upload
|
||||
cp build/bin/* upload
|
||||
|
||||
- name: Create Release AMD
|
||||
id: gitea-release-amd
|
||||
uses: actions/release-action@main
|
||||
with:
|
||||
files: |
|
||||
upload/**
|
||||
api_key: '${{ secrets.RELEASE_TOKEN }}'
|
43
.gitea/workflows/release_code.yml
Normal file
43
.gitea/workflows/release_code.yml
Normal file
|
@ -0,0 +1,43 @@
|
|||
name: Outbag Code release
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
secrets:
|
||||
|
||||
jobs:
|
||||
release-code:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Build
|
||||
run: |
|
||||
mkdir build
|
||||
npm run prepublish
|
||||
|
||||
- name: Build Code
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get install zip tar -y
|
||||
mkdir outbag_server
|
||||
mkdir outbag_server/dist
|
||||
mkdir upload
|
||||
cp -r dist/* outbag_server/dist
|
||||
cp package.json outbag_server
|
||||
cp package-lock.json outbag_server
|
||||
cp readme.md outbag_server
|
||||
zip -r upload/OutbagServer.zip outbag_server/*
|
||||
tar -czvf upload/OutbagServer.tar.gz outbag_server/*
|
||||
|
||||
- name: Create Release Code
|
||||
id: gitea-release-code
|
||||
uses: actions/release-action@main
|
||||
with:
|
||||
files: |
|
||||
upload/**
|
||||
api_key: '${{ secrets.RELEASE_TOKEN }}'
|
|
@ -1,6 +1,9 @@
|
|||
name: Outbag Tests
|
||||
|
||||
on: [push]
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
secrets:
|
||||
|
||||
jobs:
|
||||
test:
|
|
@ -4,7 +4,7 @@
|
|||
PORT=7224
|
||||
PORTexposed=7224
|
||||
PATHexposed=/
|
||||
URL=localhost
|
||||
URL=127.0.0.1
|
||||
CertLiveSec=2592000
|
||||
|
||||
[ssl]
|
||||
|
|
|
@ -18,29 +18,29 @@ const list = [
|
|||
["signup", async (req) => {
|
||||
await req({}, "signup", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
|
||||
await req({}, "signup", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.ACCOUNT_EXISTS);
|
||||
|
||||
await req({}, "signup", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
|
||||
await req({}, "signup", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.config);
|
||||
}], ["remote", async (req) => {
|
||||
let signature = (await req({ "authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}` },
|
||||
let signature = (await req({ "authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}` },
|
||||
"createSignature", {
|
||||
publicKey
|
||||
}, "ok", null)).sign;
|
||||
|
@ -51,7 +51,7 @@ const list = [
|
|||
"authorization": `Bearer ${token}`
|
||||
}, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7223",
|
||||
server: "127.0.0.1:7223",
|
||||
publicKey,
|
||||
sign: signature
|
||||
}, "error", act_error.SIGNATURE);
|
||||
|
@ -60,7 +60,7 @@ const list = [
|
|||
"authorization": `Bearer ${token}`
|
||||
}, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
publicKey,
|
||||
sign: falseSignature
|
||||
}, "error", act_error.SIGNATURE);
|
||||
|
@ -69,7 +69,7 @@ const list = [
|
|||
"authorization": `Bearer ${token}`
|
||||
}, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
publicKey,
|
||||
sign: signature
|
||||
}, "ok", null)).challenge;
|
||||
|
@ -78,7 +78,7 @@ const list = [
|
|||
"authorization": `Bearer ${token}`
|
||||
}, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
publicKey,
|
||||
sign: signature
|
||||
}, "error", act_error.WRONG_STATE);
|
||||
|
@ -97,7 +97,7 @@ const list = [
|
|||
|
||||
}], ["account", async (req) => {
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getMyAccount", {}, "ok", {
|
||||
rights: PERMISSIONS.ALL,
|
||||
name: name1,
|
||||
|
@ -107,7 +107,7 @@ const list = [
|
|||
maxUsersPerRoom: 2,
|
||||
});
|
||||
await req({
|
||||
"authorization": `Digest name=${name2} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name2} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getMyAccount", {}, "ok", {
|
||||
rights: PERMISSIONS.DEFAULT,
|
||||
name: name2,
|
||||
|
@ -118,31 +118,31 @@ const list = [
|
|||
});
|
||||
}], ["change account", async (req) => {
|
||||
await req({
|
||||
"authorization": `Digest name=${name2} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name2} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "changePassword", {
|
||||
accountKey: accountKey + "lol"
|
||||
}, "ok", "");
|
||||
await req({}, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.AUTH);
|
||||
await req({}, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey: accountKey + "lol"
|
||||
}, "ok", "");
|
||||
await req({
|
||||
"authorization": `Digest name=${name2} server=localhost:7224 accountKey=${accountKey + "lol"}`
|
||||
"authorization": `Digest name=${name2} server=127.0.0.1:7224 accountKey=${accountKey + "lol"}`
|
||||
}, "deleteAccount", {}, "ok", "");
|
||||
await req({}, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey: accountKey + "lol"
|
||||
}, "error", act_error.AUTH);
|
||||
}], ["admin", async (req) => {
|
||||
let resp = await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getAccounts", {}, "ok", [
|
||||
{
|
||||
accID: 1,
|
||||
|
@ -167,13 +167,13 @@ const list = [
|
|||
}
|
||||
]);
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "setPermissions", {
|
||||
accID: resp[1].accID,
|
||||
rights: 5
|
||||
}, "ok", "");
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getAccounts", {}, "ok", [
|
||||
{
|
||||
accID: 1,
|
||||
|
@ -198,14 +198,14 @@ const list = [
|
|||
}
|
||||
]);
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "addOTA", {
|
||||
token: "12345678",
|
||||
expires: uts() + 1,
|
||||
usesLeft: -1
|
||||
}, "ok", "");
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getOTAs", {}, "ok", [
|
||||
{
|
||||
token: "12345678",
|
||||
|
@ -214,7 +214,7 @@ const list = [
|
|||
}
|
||||
]);
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "addOTA", {
|
||||
token: "abc",
|
||||
expires: -1,
|
||||
|
@ -222,34 +222,34 @@ const list = [
|
|||
}, "ok", "");
|
||||
await wait(2000);
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getOTAs", {}, "ok", [{
|
||||
token: "abc",
|
||||
expires: -1,
|
||||
usesLeft: -1
|
||||
}]);
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "deleteOTA", { token: "abc" }, "ok", "");
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "getOTAs", {}, "ok", []);
|
||||
}], ["room Owner", async (req) => {
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "createRoom", {
|
||||
room: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 1",
|
||||
description: "some desc",
|
||||
visibility: 0,
|
||||
icon: "shopping"
|
||||
}, "ok", "");
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "createRoom", {
|
||||
room: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 1",
|
||||
description: "some desc",
|
||||
visibility: 0,
|
||||
|
@ -257,20 +257,20 @@ const list = [
|
|||
}, "error", act_error.ROOM_EXISTS);
|
||||
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "createRoom", {
|
||||
room: room2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 2",
|
||||
description: "some desc 2",
|
||||
visibility: 1,
|
||||
icon: ""
|
||||
}, "ok", "");
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "createRoom", {
|
||||
room: room3,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 2",
|
||||
description: "some desc 2",
|
||||
visibility: 1,
|
||||
|
@ -278,11 +278,11 @@ const list = [
|
|||
}, "error", act_error.ROOM_LIMIT);
|
||||
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "listRooms", {}, "ok", [
|
||||
{
|
||||
name: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
owner: name1,
|
||||
rights: 0b11111,
|
||||
title: "Test Room 1",
|
||||
|
@ -293,7 +293,7 @@ const list = [
|
|||
confirmed: true
|
||||
}, {
|
||||
name: room2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
owner: name1,
|
||||
rights: 0b11111,
|
||||
title: "Test Room 2",
|
||||
|
@ -305,32 +305,32 @@ const list = [
|
|||
}
|
||||
]);
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "deleteRoom", {
|
||||
room: room2 + "lol",
|
||||
server: "localhost:7224"
|
||||
server: "127.0.0.1:7224"
|
||||
}, "error", act_error.ROOM_NOT_EXISTS);
|
||||
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "deleteRoom", {
|
||||
room: room2,
|
||||
server: "localhost:7224"
|
||||
server: "127.0.0.1:7224"
|
||||
}, "ok", "");
|
||||
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "deleteRoom", {
|
||||
room: room2,
|
||||
server: "localhost:7224"
|
||||
server: "127.0.0.1:7224"
|
||||
}, "error", act_error.ROOM_NOT_EXISTS);
|
||||
|
||||
await req({
|
||||
"authorization": `Digest name=${name1} server=localhost:7224 accountKey=${accountKey}`
|
||||
"authorization": `Digest name=${name1} server=127.0.0.1:7224 accountKey=${accountKey}`
|
||||
}, "listRooms", {}, "ok", [
|
||||
{
|
||||
name: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
owner: name1,
|
||||
rights: 0b11111,
|
||||
title: "Test Room 1",
|
||||
|
|
|
@ -17,33 +17,33 @@ const list = [
|
|||
["signup", async (handler, req, newHandler) => {
|
||||
await req(handler, "signup", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
await req(handler, "signup", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.WRONG_STATE);
|
||||
await req(await newHandler(), "signup", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.ACCOUNT_EXISTS);
|
||||
await req(await newHandler(), "signup", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
await req(await newHandler(), "signup", {
|
||||
name: name3,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.CONFIG);
|
||||
}], ["remote", async (handler, req, newHandler) => {
|
||||
await req(handler, "signin", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
let signature = (await req(handler, "createSignature", {
|
||||
|
@ -53,25 +53,25 @@ const list = [
|
|||
let h2 = await newHandler();
|
||||
await req(h2, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7223",
|
||||
server: "127.0.0.1:7223",
|
||||
publicKey,
|
||||
sign: signature
|
||||
}, "error", act_error.SIGNATURE);
|
||||
await req(h2, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
publicKey,
|
||||
sign: falseSignature
|
||||
}, "error", act_error.SIGNATURE);
|
||||
let challenge = (await req(h2, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
publicKey,
|
||||
sign: signature
|
||||
}, "ok", null)).challenge;
|
||||
await req(h2, "remote1", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
publicKey,
|
||||
sign: signature
|
||||
}, "error", act_error.WRONG_STATE);
|
||||
|
@ -84,7 +84,7 @@ const list = [
|
|||
}], ["account", async (handler, req, newHandler) => {
|
||||
await req(handler, "signin", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
await req(handler, "getMyAccount", {}, "ok", {
|
||||
|
@ -98,7 +98,7 @@ const list = [
|
|||
let h2 = await newHandler();
|
||||
await req(h2, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
await req(h2, "getMyAccount", {}, "ok", {
|
||||
|
@ -112,7 +112,7 @@ const list = [
|
|||
}], ["change account", async (handler, req, newHandler) => {
|
||||
await req(handler, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
await req(handler, "changePassword", {
|
||||
|
@ -121,12 +121,12 @@ const list = [
|
|||
let h2 = await newHandler();
|
||||
await req(h2, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "error", act_error.AUTH);
|
||||
await req(h2, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey: accountKey + "lol"
|
||||
}, "ok", "");
|
||||
await req(h2, "deleteAccount", {}, "ok", "");
|
||||
|
@ -134,18 +134,18 @@ const list = [
|
|||
let h3 = await newHandler();
|
||||
await req(h3, "signin", {
|
||||
name: name2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey: accountKey + "lol"
|
||||
}, "error", act_error.AUTH);
|
||||
}], ["room Owner", async (handler, req, newHandler) => {
|
||||
await req(handler, "signin", {
|
||||
name: name1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
accountKey
|
||||
}, "ok", "");
|
||||
await req(handler, "createRoom", {
|
||||
room: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 1",
|
||||
description: "some desc",
|
||||
visibility: 0,
|
||||
|
@ -153,7 +153,7 @@ const list = [
|
|||
}, "ok", "");
|
||||
await req(handler, "createRoom", {
|
||||
room: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 1",
|
||||
description: "some desc",
|
||||
visibility: 0,
|
||||
|
@ -162,7 +162,7 @@ const list = [
|
|||
|
||||
await req(handler, "createRoom", {
|
||||
room: room2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 2",
|
||||
description: "some desc 2",
|
||||
visibility: 1,
|
||||
|
@ -171,7 +171,7 @@ const list = [
|
|||
|
||||
await req(handler, "createRoom", {
|
||||
room: room3,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
title: "Test Room 2",
|
||||
description: "some desc 2",
|
||||
visibility: 1,
|
||||
|
@ -181,7 +181,7 @@ const list = [
|
|||
await req(handler, "listRooms", {}, "ok", [
|
||||
{
|
||||
name: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
owner: name1,
|
||||
rights: 0b11111,
|
||||
title: "Test Room 1",
|
||||
|
@ -192,7 +192,7 @@ const list = [
|
|||
confirmed: true
|
||||
}, {
|
||||
name: room2,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
owner: name1,
|
||||
rights: 0b11111,
|
||||
title: "Test Room 2",
|
||||
|
@ -205,20 +205,20 @@ const list = [
|
|||
]);
|
||||
await req(handler, "deleteRoom", {
|
||||
room: room2 + "lol",
|
||||
server: "localhost:7224"
|
||||
server: "127.0.0.1:7224"
|
||||
}, "error", act_error.ROOM_NOT_EXISTS);
|
||||
await req(handler, "deleteRoom", {
|
||||
room: room2,
|
||||
server: "localhost:7224"
|
||||
server: "127.0.0.1:7224"
|
||||
}, "ok", "");
|
||||
await req(handler, "deleteRoom", {
|
||||
room: room2,
|
||||
server: "localhost:7224"
|
||||
server: "127.0.0.1:7224"
|
||||
}, "error", act_error.ROOM_NOT_EXISTS);
|
||||
await req(handler, "listRooms", {}, "ok", [
|
||||
{
|
||||
name: room1,
|
||||
server: "localhost:7224",
|
||||
server: "127.0.0.1:7224",
|
||||
owner: name1,
|
||||
rights: 0b11111,
|
||||
title: "Test Room 1",
|
||||
|
|
Loading…
Reference in a new issue