File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # Git
2+ .git
3+ .gitignore
4+ .github
5+
6+ # Claude/AI configuration
7+ .claude
8+ .serena
9+ CLAUDE.md
10+
11+ # Documentation
12+ * .md
13+ ! README.md
14+
15+ # Test artifacts
16+ coverage /
17+ test_db
18+ * .sqlite3
19+ .last_run.json
20+ .resultset.json
21+
22+ # Ruby/bundler
23+ .bundle
24+ vendor /bundle
25+
26+ # OS files
27+ .DS_Store
28+ Thumbs.db
29+
30+ # Editor files
31+ .vscode
32+ .idea
33+ * .swp
34+ * .swo
35+ * ~
Original file line number Diff line number Diff line change 88Gemfile.lock
99InstalledFiles
1010_yardoc
11- coverage
11+ coverage /
1212doc /
1313lib /bundler /man
1414pkg
@@ -17,7 +17,6 @@ spec/reports
1717test /tmp
1818test /version_tmp
1919tmp
20- coverage
2120test /log
2221log /* .log
2322test_db
Original file line number Diff line number Diff line change 1+ # Dockerfile for testing jsonapi-resources with multiple Rails versions
2+ FROM ruby:3.2
3+
4+ # Install dependencies
5+ RUN apt-get update -qq && \
6+ apt-get install -y build-essential libsqlite3-dev nodejs && \
7+ apt-get clean && \
8+ rm -rf /var/lib/apt/lists/*
9+
10+ # Set working directory
11+ WORKDIR /app
12+
13+ # Copy gemspec and Gemfile first for better caching
14+ COPY jsonapi-resources.gemspec Gemfile ./
15+ COPY lib/jsonapi/resources/version.rb ./lib/jsonapi/resources/
16+
17+ # Install bundler
18+ RUN gem install bundler
19+
20+ # Set default Rails version (can be overridden via build arg or env var)
21+ ARG RAILS_VERSION=6.1.7.10
22+ ENV RAILS_VERSION=${RAILS_VERSION}
23+
24+ # Install dependencies
25+ RUN bundle install
26+
27+ # Copy the rest of the application
28+ COPY . .
29+
30+ # Default command runs tests
31+ CMD ["bundle" , "exec" , "rake" , "test" ]
Original file line number Diff line number Diff line change 1+ services :
2+ # Base service definition
3+ test-base : &test-base
4+ build :
5+ context : .
6+ dockerfile : Dockerfile
7+ volumes :
8+ - .:/app
9+ - bundle-cache:/usr/local/bundle
10+ working_dir : /app
11+ stdin_open : true
12+ tty : true
13+
14+ # Rails 6.1.7.10
15+ rails-6.1 :
16+ << : *test-base
17+ container_name : jsonapi-rails-6.1
18+ environment :
19+ - RAILS_VERSION=6.1.7.10
20+ command : bash -c "bundle update && bundle exec rake test"
21+
22+ # Rails 7.0.10
23+ rails-7.0 :
24+ << : *test-base
25+ container_name : jsonapi-rails-7.0
26+ environment :
27+ - RAILS_VERSION=7.0.10
28+ command : bash -c "bundle update && bundle exec rake test"
29+
30+ # Rails 7.1.6
31+ rails-7.1 :
32+ << : *test-base
33+ container_name : jsonapi-rails-7.1
34+ environment :
35+ - RAILS_VERSION=7.1.6
36+ command : bash -c "bundle update && bundle exec rake test"
37+
38+ # Rails 7.2.3
39+ rails-7.2 :
40+ << : *test-base
41+ container_name : jsonapi-rails-7.2
42+ environment :
43+ - RAILS_VERSION=7.2.3
44+ command : bash -c "bundle update && bundle exec rake test"
45+
46+ # Rails 8.0.4
47+ rails-8.0 :
48+ << : *test-base
49+ container_name : jsonapi-rails-8.0
50+ environment :
51+ - RAILS_VERSION=8.0.4
52+ command : bash -c "bundle update && bundle exec rake test"
53+
54+ # Rails 8.1.2
55+ rails-8.1 :
56+ << : *test-base
57+ container_name : jsonapi-rails-8.1
58+ environment :
59+ - RAILS_VERSION=8.1.2
60+ command : bash -c "bundle update && bundle exec rake test"
61+
62+ # Interactive shell for debugging (defaults to Rails 6.1)
63+ shell :
64+ << : *test-base
65+ container_name : jsonapi-shell
66+ environment :
67+ - RAILS_VERSION=${RAILS_VERSION:-6.1.7.10}
68+ command : /bin/bash
69+
70+ volumes :
71+ bundle-cache :
You can’t perform that action at this time.
0 commit comments