Skip to content

Commit 8b7b3c0

Browse files
committed
fix: update tests and fix running on main-0.6
1 parent 4e38954 commit 8b7b3c0

7 files changed

Lines changed: 60 additions & 76 deletions

File tree

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Run tests
33
on:
44
pull_request:
55
push:
6-
branches: [main]
6+
branches: [main, main-0.6]
77

88
concurrency:
99
group: ${{ github.ref_name }}

Cargo.lock

Lines changed: 38 additions & 54 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ members = [
66
resolver = "2"
77

88
[workspace.dependencies]
9-
hdi = "0.7.0-dev.13"
10-
hdk = "0.6.0-dev.15"
9+
hdi = "0.7.1-rc.1"
10+
hdk = "0.6.1-rc.1"
1111
holochain_serialized_bytes = "0.0.56"
1212
serde = "1.0.192"
1313

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ts/src/conductor.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,10 @@ export class Conductor {
273273
});
274274
}
275275

276-
setNetworkConfig(createConductorOptions: NetworkConfig, signalingServerUrl?: URL) {
276+
setNetworkConfig(
277+
createConductorOptions: NetworkConfig,
278+
signalingServerUrl?: URL,
279+
) {
277280
const conductorConfig = readFileSync(
278281
`${this.conductorDir}/${CONDUCTOR_CONFIG}`,
279282
"utf-8",

ts/test/conductor.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ test("Conductor with custom bootstrap server", async () => {
5050
});
5151

5252
test("Conductor with custom signaling server", async () => {
53-
const signalingServerUrl = new URL("ws://some-signal.server:1234");
53+
const signalingServerUrl = new URL("http://some-signal.server:1234");
5454
const conductor = await createConductor(signalingServerUrl, {
5555
startup: false,
5656
});

ts/test/scenario.test.ts

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,6 @@ test("Set custom network config", async () => {
120120
const minInitiateIntervalMs = 20_000;
121121
const initiateJitterMs = 5_000;
122122
const roundTimeoutMs = 20_000;
123-
const transportTimeoutS = 1_000;
124123
const targetArcFactor = 0;
125124

126125
const alice = await scenario.addPlayerWithApp({
@@ -134,7 +133,6 @@ test("Set custom network config", async () => {
134133
minInitiateIntervalMs,
135134
initiateJitterMs,
136135
roundTimeoutMs,
137-
transportTimeoutS,
138136
targetArcFactor,
139137
},
140138
},
@@ -158,15 +156,15 @@ test("Set custom network config", async () => {
158156
assert.strictEqual(network.target_arc_factor, targetArcFactor);
159157

160158
assert.ok(
161-
advanced && typeof advanced === "object" && "tx5Transport" in advanced,
159+
advanced && typeof advanced === "object" && "irohTransport" in advanced,
162160
);
163-
const { tx5Transport } = advanced;
161+
const { irohTransport } = advanced;
164162
assert.ok(
165-
tx5Transport &&
166-
typeof tx5Transport === "object" &&
167-
"timeoutS" in tx5Transport,
163+
irohTransport &&
164+
typeof irohTransport === "object" &&
165+
"relayAllowPlainText" in irohTransport,
168166
);
169-
assert.strictEqual(tx5Transport.timeoutS, transportTimeoutS);
167+
assert.strictEqual(irohTransport.relayAllowPlainText, true);
170168

171169
assert.ok(advanced && typeof advanced === "object" && "k2Gossip" in advanced);
172170
const { k2Gossip } = advanced;
@@ -192,7 +190,6 @@ test("Default network config", async () => {
192190
const minInitiateIntervalMs = 3_000;
193191
const initiateJitterMs = 1_000;
194192
const roundTimeoutMs = 5_000;
195-
const transportTimeoutS = 15;
196193
const targetArcFactor = 1;
197194

198195
const alice = await scenario.addPlayerWithApp({
@@ -220,15 +217,15 @@ test("Default network config", async () => {
220217
assert.strictEqual(network.target_arc_factor, targetArcFactor);
221218

222219
assert.ok(
223-
advanced && typeof advanced === "object" && "tx5Transport" in advanced,
220+
advanced && typeof advanced === "object" && "irohTransport" in advanced,
224221
);
225-
const { tx5Transport } = advanced;
222+
const { irohTransport } = advanced;
226223
assert.ok(
227-
tx5Transport &&
228-
typeof tx5Transport === "object" &&
229-
"timeoutS" in tx5Transport,
224+
irohTransport &&
225+
typeof irohTransport === "object" &&
226+
"relayAllowPlainText" in irohTransport,
230227
);
231-
assert.strictEqual(tx5Transport.timeoutS, transportTimeoutS);
228+
assert.strictEqual(irohTransport.relayAllowPlainText, true);
232229

233230
assert.ok(advanced && typeof advanced === "object" && "k2Gossip" in advanced);
234231
const { k2Gossip } = advanced;

0 commit comments

Comments
 (0)