How to use the @codechecks/client.codechecks.success function in @codechecks/client

To help you get started, we’ve selected a few @codechecks/client examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github cgewecke / eth-gas-reporter / codechecks.js View on Github external
output.config.previousData = await codechecks.getValue(output.namespace);
  } catch (err) {
    console.log(
      `If you have a chance, report this incident to the eth-gas-reporter github issues.`
    );
    console.log(`Codechecks errored running 'getValue'...\n${err}\n`);
    return;
  }

  const report = new CodeChecksReport(output.config);
  const table = report.generate(output.info);
  const shortDescription = report.getShortDescription();

  // Submit report
  try {
    await codechecks.success({
      name: "Gas Usage",
      shortDescription: shortDescription,
      longDescription: table
    });
  } catch (err) {
    console.log(
      `If you have a chance, report this incident to the eth-gas-reporter github issues.`
    );
    console.log(`Codechecks errored running 'success'...\n${err}\n`);
    console.log(`Short description was: ${shortDescription}`);
    console.log(`Table was: ${table}`);
  }
};
github codechecks / monorepo / checks / semaphore.ts View on Github external
export default async function() {
  await codechecks.success({
    name: "Semaphore",
    shortDescription: "works!",
    longDescription: "```\n" + JSON.stringify(codechecks.context, null, 2) + "\n```\n",
  });
}