Skip to content

antoniomnds/ebook_store

Repository files navigation

📚 Ebook Store CI codecov

A simple full-stack Rails application for managing ebooks, which can be bought/sold by users.

Built as a portfolio project to demonstrate testing practices, model design (including polymorphic associations), and clean Rails architecture.


🚀 Features

  • User authentication using has_secure_password
  • Full CRUD for ebooks and users
  • Tagging system with a polymorphic join model (Tagging)
  • Email notifications on key events (e.g., user registration)
  • Thorough test coverage using RSpec (models, requests, system, mailers, views, routing)
  • Modern UI styled using Bootstrap
  • Ready for CI and PostgreSQL migration

🔧 Setup

git clone https://github.com/antoniomnds/ebook_store.git
cd ebook_store
bundle install
rails db:setup
cp .env.example .env

⚠️ Note: App currently uses SQLite for local development. Plan includes migrating to PostgreSQL for production readiness.


🧪 Running Tests

bundle exec rspec

Optionally run rubocop code formatter:

bundle exec rubocop -a -f g

Coverage with:

open coverage/index.html

🛠️ Tech Stack


🧠 Notable Design Choices

  • Tagging is a polymorphic join model (ebooks, authors, etc.)
  • System specs simulate real user behavior (login, navigation)
  • View specs validate rendering of key UI elements
  • Database constraints align with validations (e.g., uniqueness + unique index)

🚀 Deployment (Planned)

  • PostgreSQL migration
  • GitHub Actions CI pipeline with tests
  • Deployment to Render, Fly.io or Railway

👤 Author

António Santos
LinkedIn

About

A virtual store of ebooks

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •