https://github.com/wbotelhos/simple_store
🛒 Simple Store
https://github.com/wbotelhos/simple_store
challenge ruby store
Last synced: 2 months ago
JSON representation
🛒 Simple Store
- Host: GitHub
- URL: https://github.com/wbotelhos/simple_store
- Owner: wbotelhos
- Created: 2023-09-02T22:49:10.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-09-03T00:24:14.000Z (almost 3 years ago)
- Last Synced: 2026-02-15T06:14:41.627Z (5 months ago)
- Topics: challenge, ruby, store
- Language: Ruby
- Homepage: https://wbotelhos.com
- Size: 35.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# Simple Store
[](https://github.com/wbotelhos/simple_store/actions)
[](https://codeclimate.com/github/wbotelhos/simple_store/maintainability)
[](https://codecov.io/gh/wbotelhos/simple_store)
It's a simple store receiving a list of products and the desired quantity along with some product's characteristics then the code responds with the line items containing the price for each product, the taxes and the total.
## Setup
Using Docker:
```sh
docker build . -t simple_store
```
Using your local machine:
```rb
git clone https://github.com/wbotelhos/simple_store
cd simple_store
bundle install
```
## How to Run?
Or using Docker:
```sh
docker run -i simple_store ruby run.rb < data/input.txt
```
Using your local machine:
```sh
ruby run.rb < data/input.txt
```
## Tests
The main test with the example cases from the [TODO](https://github.com/wbotelhos/simple_store/blob/main/TODO.md) file
is [this one](https://github.com/wbotelhos/simple_store/blob/main/spec/calculator_spec.rb).
Using Docker:
```sh
docker run simple_store bundle exec rspec
```
Using your local machine:
```rb
rspec
```