- Build the Docker image:
docker build -t csv_to_json_converter .
- Run the tests:
docker run csv_to_json_converter
- Install Bundler if you haven't:
gem install bundler
- Install required gems:
bundle install
- Run the tests:
ruby test_script.rb
- Run the script:
ruby script.rb sample.csv
- Used Ruby's standard CSV and JSON libraries for simplicity.
- Added a Gemfile for easier dependency management.
- Added error handling for file not found and malformed CSV scenarios.