fix: Remove fs dep, bpf_loader now takes ELF as bytes

This commit is contained in:
Jack May
2018-10-25 10:41:18 -07:00
committed by Michael Vines
parent 224d929d4d
commit f871b0410a
4 changed files with 3175 additions and 3175 deletions

View File

@ -1,5 +1,7 @@
// @flow
import fs from 'mz/fs';
import {
Connection,
BpfLoader,
@ -23,7 +25,8 @@ test('load BPF program', async () => {
const connection = new Connection(url);
const from = await newAccountWithTokens(connection);
const programId = await BpfLoader.load(connection, from, 'test/bin/noop_c.o');
const data = await fs.readFile('test/bin/noop_c.o');
const programId = await BpfLoader.load(connection, from, data);
const transaction = new Transaction().add({
keys: [from.publicKey],
programId,