Skip to content

Mozilla-Club-IIT/codedrop-challenges

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CodeDrop Test Cases

A Rust project for managing and running test cases.

Getting Started

Prerequisites

  • Rust and Cargo installed on your system

Running the Project

# Run the project
cargo run

# Run with release optimizations
cargo run --release

# Run tests
cargo test

# Build the project
cargo build

Adding Test Cases

To add a new test case:

  1. Create input and output files in ./testcases/[challenge_no]/
    • Input file: ./testcases/[challenge_no]/[testcase_no]_input.txt
    • Output file: ./testcases/[challenge_no]/[testcase_no]_output.txt
    • Example: ./testcases/01/02_input.txt and ./testcases/01/02_output.txt for challenge 1, test case 2
  2. The input file should contain the test input data as specified in the HackerRank listing
  3. The output file should contain the expected output for the corresponding input
  4. Follow the existing test case format and directory structure
  5. Run cargo run to verify your test case works correctly

Test Case Directory Structure

./testcases/
├── 01/
│   ├── 01_input.txt
│   ├── 01_output.txt
│   ├── 02_input.txt
│   ├── 02_output.txt
│   ├── 03_input.txt
│   └── 03_output.txt
├── 02/
│   ├── 01_input.txt
│   ├── 01_output.txt
│   ├── 02_input.txt
│   └── 02_output.txt
└── ...

About

Test cases for the CodeDrop hackathon

Resources

Stars

Watchers

Forks

Contributors