Skip to content

Commit

Permalink
Update few e2e tests after code review
Browse files Browse the repository at this point in the history
  • Loading branch information
nazarhussain committed Sep 18, 2023
1 parent 0b43ef7 commit dbee69d
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 92 deletions.
2 changes: 0 additions & 2 deletions packages/beacon-node/test/e2e/api/impl/config.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ const CONSTANT_NAMES_SKIP_LIST = new Set([
]);

describe("api / impl / config", function () {
this.timeout(60 * 1000);

it("Ensure all constants are exposed", async () => {
const constantNames = await downloadRemoteConstants(ethereumConsensusSpecsTests.specVersion);

Expand Down
35 changes: 0 additions & 35 deletions packages/beacon-node/test/e2e/api/impl/getBlobSidecars.test.ts

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ describe("lightclient api", function () {
let validators: Validator[];
const afterEachCallbacks: (() => Promise<unknown> | void)[] = [];

this.beforeEach(async () => {
before(async () => {
bn = await getDevBeaconNode({
params: chainConfig,
options: {
Expand All @@ -41,7 +41,7 @@ describe("lightclient api", function () {
rest: {
enabled: true,
port: restPort,
api: ["lightclient"],
// api: ["lightclient"],
},
},
chain: {blsVerifyAllMainThread: true},
Expand All @@ -64,7 +64,7 @@ describe("lightclient api", function () {
afterEachCallbacks.push(() => Promise.all(validators.map((validator) => validator.close())));
});

afterEach(async () => {
after(async () => {
while (afterEachCallbacks.length > 0) {
const callback = afterEachCallbacks.pop();
if (callback) await callback();
Expand Down Expand Up @@ -120,10 +120,9 @@ describe("lightclient api", function () {
it("getCommitteeRoot() for the 1st period", async function () {
await waitForBestUpdate();

const lightclient = getClient({baseUrl: `http://127.0.0.1:${restPort}`}, {config}).lightclient;
const {lightclient, beacon: client} = getClient({baseUrl: `http://127.0.0.1:${restPort}`}, {config});
const committeeRes = await lightclient.getCommitteeRoot(0, 1);
ApiError.assert(committeeRes);
const client = getClient({baseUrl: `http://127.0.0.1:${restPort}`}, {config}).beacon;
const validatorResponse = await client.getStateValidators("head");
ApiError.assert(validatorResponse);
const pubkeys = validatorResponse.response.data.map((v) => v.validator.pubkey);
Expand Down
3 changes: 1 addition & 2 deletions packages/beacon-node/test/e2e/api/lodestar/lodestar.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@ describe("api / impl / validator", function () {
const genesisValidatorsRoot = Buffer.alloc(32, 0xaa);
const config = createBeaconConfig(chainConfig, genesisValidatorsRoot);

const testLoggerOpts: TestLoggerOpts = {level: LogLevel.info};
const loggerNodeA = testLogger("Node-A", testLoggerOpts);
const loggerNodeA = testLogger("Node-A");

const bn = await getDevBeaconNode({
params: testParams,
Expand Down
2 changes: 2 additions & 0 deletions packages/beacon-node/test/e2e/chain/bls/multithread.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ describe("chain / bls / multithread queue", function () {
expect(isValid).to.deep.equal([true, true, true], `sig set ${i} returned invalid`);
}
}
await pool.close();
}

for (const priority of [true, false]) {
Expand Down Expand Up @@ -122,6 +123,7 @@ describe("chain / bls / multithread queue", function () {
for (const [i, isValid] of isValidArr.entries()) {
expect(isValid).to.equal(true, `sig set ${i} returned invalid`);
}
await pool.close();
});
}
});
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import {BeaconNode} from "../../../src/node/index.js";
//
// Attempting to do both 1. and 2. in this e2e test more expensive than necessary.
// Unit tests in the validator cover 2., so some test in lodestar package should cover 1.
// https://github.com/ChainSafe/lodestar/issues/5967
describe.skip("doppelganger / doppelganger test", function () {
const afterEachCallbacks: (() => Promise<unknown> | void)[] = [];
afterEach(async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ const pyrmontDepositsDataRoot = [
"0x61cef7d8a3f7c590a2dc066ae1c95def5ce769b3e9471fdb34f36f7a7246965e",
];

// https://github.com/ChainSafe/lodestar/issues/5967
describe.skip("eth1 / Eth1Provider", function () {
this.timeout("2 min");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {getGoerliRpcUrl} from "../../testParams.js";
// This test is constantly failing. We must unblock PR so this issue is a TODO to debug it and re-enable latter.
// It's OKAY to disable temporarily since this functionality is tested indirectly by the sim merge tests.
// See https://github.com/ChainSafe/lodestar/issues/4197
// https://github.com/ChainSafe/lodestar/issues/5967
describe.skip("eth1 / Eth1MergeBlockTracker", function () {
this.timeout("2 min");

Expand Down
1 change: 1 addition & 0 deletions packages/beacon-node/test/e2e/eth1/eth1Provider.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import {Eth1Provider, parseEth1Block} from "../../../src/eth1/provider/eth1Provi
import {Eth1Block} from "../../../src/eth1/interface.js";
import {getGoerliRpcUrl} from "../../testParams.js";

// https://github.com/ChainSafe/lodestar/issues/5967
describe.skip("eth1 / Eth1Provider", function () {
this.timeout("2 min");

Expand Down
1 change: 1 addition & 0 deletions packages/beacon-node/test/e2e/eth1/stream.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {Eth1Provider} from "../../../src/eth1/provider/eth1Provider.js";
import {getGoerliRpcUrl} from "../../testParams.js";
import {Eth1Options} from "../../../src/eth1/options.js";

// https://github.com/ChainSafe/lodestar/issues/5967
describe.skip("Eth1 streams", function () {
this.timeout("2 min");

Expand Down
1 change: 1 addition & 0 deletions packages/beacon-node/test/e2e/network/mdns.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import {memoOnce} from "../../utils/cache.js";
let port = 9000;
const mu = "/ip4/127.0.0.1/tcp/0";

// https://github.com/ChainSafe/lodestar/issues/5967
// eslint-disable-next-line mocha/no-skipped-tests
describe.skip("mdns", function () {
this.timeout(50000);
Expand Down
13 changes: 0 additions & 13 deletions packages/beacon-node/test/e2e/network/onWorker/workerEcho.ts

This file was deleted.

This file was deleted.

0 comments on commit dbee69d

Please sign in to comment.