mirror of https://github.com/embarklabs/embark.git
fix linting
This commit is contained in:
parent
0bdcb1f41b
commit
b196a54a30
|
@ -1,6 +1,6 @@
|
||||||
import PropTypes from "prop-types";
|
import PropTypes from "prop-types";
|
||||||
import React, {Component} from 'react';
|
import React, {Component} from 'react';
|
||||||
import {Grid, Card, Form, Tabs, Tab, TabbedHeader, TabbedContainer} from 'tabler-react';
|
import {Grid, Card, Form, Tab, TabbedHeader, TabbedContainer} from 'tabler-react';
|
||||||
import Logs from "./Logs";
|
import Logs from "./Logs";
|
||||||
import Convert from 'ansi-to-html';
|
import Convert from 'ansi-to-html';
|
||||||
|
|
||||||
|
|
|
@ -44,18 +44,10 @@ export function getProcesses(state) {
|
||||||
return state.entities.processes;
|
return state.entities.processes;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getProcess(state, name) {
|
|
||||||
return state.entities.processes.find((process) => process.name === name);
|
|
||||||
}
|
|
||||||
|
|
||||||
export function getProcessLogs(state) {
|
export function getProcessLogs(state) {
|
||||||
return state.entities.processLogs;
|
return state.entities.processLogs;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getProcessLogsByProcess(state, processName) {
|
|
||||||
return state.entities.processLogs.filter((processLog => processLog.name === processName));
|
|
||||||
}
|
|
||||||
|
|
||||||
export function getContractLogsByContract(state, contractName) {
|
export function getContractLogsByContract(state, contractName) {
|
||||||
return state.entities.contractLogs.filter((contractLog => contractLog.name === contractName));
|
return state.entities.contractLogs.filter((contractLog => contractLog.name === contractName));
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
process.on('uncaughtException', function(e){
|
process.on('uncaughtException', function(e) {
|
||||||
process.send({error: e.stack});
|
process.send({error: e.stack});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -321,7 +321,7 @@ class ContractSource {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(node.type != 'b') coverage[node.type][node.id]++;
|
if(node.type !== 'b') coverage[node.type][node.id]++;
|
||||||
|
|
||||||
if(!node.parent) return;
|
if(!node.parent) return;
|
||||||
|
|
||||||
|
@ -341,7 +341,7 @@ class ContractSource {
|
||||||
}
|
}
|
||||||
|
|
||||||
_instructionLength(instruction) {
|
_instructionLength(instruction) {
|
||||||
if(instruction.indexOf('PUSH') == -1) return 1;
|
if(instruction.indexOf('PUSH') === -1) return 1;
|
||||||
return parseInt(instruction.match(/PUSH(\d+)/m)[1], 10) + 1;
|
return parseInt(instruction.match(/PUSH(\d+)/m)[1], 10) + 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,7 +50,7 @@ class ContractFuzzer {
|
||||||
}
|
}
|
||||||
case kind === "bool":
|
case kind === "bool":
|
||||||
return self.generateRandomBool();
|
return self.generateRandomBool();
|
||||||
case kind == "uint" || kind == "int":
|
case kind === "uint" || kind === "int":
|
||||||
return self.generateRandomInt(size || 256);
|
return self.generateRandomInt(size || 256);
|
||||||
case kind === "bytes":
|
case kind === "bytes":
|
||||||
return self.generateRandomStaticBytes(size || 32);
|
return self.generateRandomStaticBytes(size || 32);
|
||||||
|
|
Loading…
Reference in New Issue