Coder Social home page Coder Social logo

hdp-test's Introduction

HDP Test

This repository contains all the fixture support from HDP.

Fixtures

This guide provides detailed instructions for running integration tests using the Makefile in the HDP project. These examples demonstrate how to process requests and integrate them with the Cairo Program. Before starting, ensure you have the RPC_URL and CHAIN_ID set in your .env file, as the scripts utilize configuration from environment variables.

Generate Fixtures with command script

commands.json is the one stacks all the command that will generate fixtures by running:

./run_commands.sh <scope> commands.json`

for the scope, you could add either tag of the commands.json or just put "all" for execute everything.

Generate New Fixture

Simply run: wip: currently there are some issues for a supported query that match with randomized values, be might require comment out/in to handle the cases

cargo run

Setup and Test Execution

Follow these steps to set up and run integration tests:

  1. Setup Cairo Environment: Sets up the virtual environment required for testing, including Cairo VM.

    cargo make cairo-setup

    If you don't have cairo1-run binary installed, try running this script also:

    cargo make caior1-setup
  2. Run Integration Test: You need to position compiled_cairo program from HDP-Cairo and position in build/compiled_cairo path.

    Verify that you are in the correct environment to run cairo-run. This step executes all provided fixtures input files against the compiled Cairo program.

    cargo make integration-test

Fast Setup and Test Execution

If want to run full flow in one command, try:

 cargo make run-full-flow

And if want to reset all the setup and compiled files to back the initial state, try:

cargo make reset-setup

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.