Skip to content

Commit

Permalink
Test to comment the server spec part
Browse files Browse the repository at this point in the history
  • Loading branch information
malparty committed Jun 5, 2023
1 parent 9e9a73d commit 18fc0ac
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 14 deletions.
2 changes: 2 additions & 0 deletions .env
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ MAILER_SENDER=Test <[email protected]>
AVAILABLE_LOCALES=en
DEFAULT_LOCALE=en
FALLBACK_LOCALES=en

SECRET_KEY_BASE=replace_with_lengthy_secure_hex
2 changes: 1 addition & 1 deletion .env.development.example
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# DO NOT COMMIT THIS FILE.
# DO NOT COMMIT THIS FILE (`.env.development`)
# Rename it to `.env.development` and use it for local secrets only.

# Used to verify the integrity of signed cookies. so ensure a secure value is set
Expand Down
4 changes: 1 addition & 3 deletions .template/addons/docker/Dockerfile.tt
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,7 @@ RUN rm -rf tmp/docker
# Compile assets
RUN bin/rails i18n:js:export
RUN bin/rails assets:precompile
RUN bundle exec rake i18n:js:export
RUN yarn build
RUN yarn build:css
RUN yarn postcss

<%- end -%>
EXPOSE $PORT
Expand Down
8 changes: 0 additions & 8 deletions .template/spec/support/serverspec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,14 @@ module ServerSpecHelpers
# Prebuild and run docker image before running the test
# Because the docker api does not support docker compose
def self.test_container
puts 'HERERERERERE'
puts 'HERERERERERE'
puts ENV.fetch('APP_NAME')
puts `docker ps`
container_id = `docker ps -qf "name=#{ENV.fetch('APP_NAME')}_test"`
puts 'Container ID:'
puts container_id

Docker::Container.get(container_id.strip)
end
end

RSpec.configure do |config|
config.before(:suite) do
puts 'BEFORE SUITE'
container = ServerSpecHelpers.test_container

set :os, family: :debian
Expand All @@ -30,7 +23,6 @@ def self.test_container
end

config.after(:suite) do
puts 'AFTER SUITE'
container = ServerSpecHelpers.test_container

container.stop
Expand Down
2 changes: 1 addition & 1 deletion .template/variants/web/package.json.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
run 'yarn add postcss postcss-cli autoprefixer'

run 'yarn add --dev @nimblehq/[email protected]'
run 'yarn add --dev stylelint'
run 'yarn add --dev stylelint@14'
run 'yarn add --dev @nimblehq/stylelint-config-nimble'

# Setup scripts
Expand Down
2 changes: 1 addition & 1 deletion .template/variants/web/template.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def apply_web_variant!
use_source_path __dir__

# Generate translation file
run 'bin/rake i18n:js:export'
run 'bundle exec rake i18n:js:export'

# Fix the default Rails template that does not put trailing commas
run 'yarn run codebase:fix'
Expand Down

0 comments on commit 18fc0ac

Please sign in to comment.