Skip to content
This repository has been archived by the owner on Jul 10, 2024. It is now read-only.

Feature/add event models #34

Open
wants to merge 42 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
6947cd1
feat: update gitignore
eiguike Mar 14, 2018
40de523
feat: add docker files
eiguike Mar 14, 2018
096a9bd
refact: change database.yml to make docker work for this rails app
eiguike Mar 14, 2018
107a3db
doc: docker feature, how to build and to use
eiguike Mar 14, 2018
5e48bf0
Merge branch 'master' into docker_feature
eiguike Mar 19, 2018
7aead9f
Added event model. Still rewriting everything
Jostavo Apr 19, 2018
1b8de60
Almost done, still need to add bootstrap components and test the plat…
Jostavo Apr 19, 2018
8097247
Added DangerCI to the project
Jostavo Apr 20, 2018
1fba18c
Changed CircleCI config file
Jostavo Apr 20, 2018
b469e8d
Added pronto config file
Jostavo Apr 20, 2018
162dcec
Added necessary gems
Jostavo Apr 20, 2018
dc88af9
Fixing Dangerfile...hopefully
Jostavo Apr 20, 2018
b7afd26
Changed path to test results on CircleCI
Jostavo Apr 20, 2018
affa005
Alterações relativas às configurações do repo e adicionado modelo de …
Jostavo Apr 20, 2018
729aef6
Added dropdown menu
Jostavo Apr 21, 2018
6e0d53e
changed root routes
Jostavo May 2, 2018
82638c5
refact: change docker-compose.yml, passing correct parameters to use …
eiguike May 4, 2018
d87cd6b
refact: set the default value for login and password
eiguike May 4, 2018
bd87866
fix: merge conflicts in README.md
eiguike May 4, 2018
7c2f58e
refact: changes in circleci's file
eiguike May 5, 2018
1797fc4
refact: changes in database.yml
eiguike May 5, 2018
7728c70
Merge remote-tracking branch 'remotes/origin/feature/add-event-models…
eiguike May 5, 2018
1e7f928
refact: add cmake to install within docker
eiguike May 5, 2018
ec3debb
refact: get variable environtment for host in database.yml
eiguike May 5, 2018
036a89f
refact: rollback changes in circle-ci configuraiton, add new environm…
eiguike May 5, 2018
0a8ce06
refact: add new exceptions for gitignore
eiguike May 5, 2018
7a1090d
refact: delete useless files
eiguike May 5, 2018
707c83a
Merge pull request #28 from caccs/docker_feature
Jostavo May 6, 2018
a4bf298
Now able to show a single event
Jostavo May 9, 2018
96fa2e1
Fix to DangerCI warnings. Some of them will be ignored
Jostavo May 9, 2018
eb3d65d
fixed problem with dependencies here on the PR too
Jostavo Aug 27, 2018
c87967a
Merge branch 'master' into feature/add-event-models
Jostavo Aug 27, 2018
4c56629
trying to fix problem with dependencies (remove required)
Jostavo Aug 28, 2018
3f034f5
Merge branch 'feature/add-event-models' of https://github.com/caccs/c…
Jostavo Aug 28, 2018
ef1a5d9
trying to find the problem with the dangerfile
Jostavo Aug 28, 2018
5f427c7
wth is happening
Jostavo Aug 28, 2018
1bca790
committing new Dangerfile (changed to UTF-8)
Jostavo Aug 28, 2018
aebbb72
w/e
Jostavo Aug 28, 2018
4c2a975
maybe changing vm config file will work better
Jostavo Aug 28, 2018
7bcc3d5
removed some verifications. I guess the problem is we are verifying f…
Jostavo Aug 29, 2018
a1c03e9
-_-
Jostavo Aug 29, 2018
dc2693e
just small fixes as pointed by our bot
Jostavo Aug 29, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
79 changes: 57 additions & 22 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,56 +5,91 @@ jobs:
- image: circleci/ruby:2.4.1-node-browsers
environment:
PGHOST: 127.0.0.1
PGUSER: root
PGUSER: postgres
POSTGRES_PASSWORD: postgres
RAILS_ENV: development

- image: circleci/postgres:9.4
environment:
POSTGRES_USER: root
POSTGRES_USER: postgres
POSTGRES_DB: development
POSTGRES_PASSWORD: circleci_test
POSTGRES_PASSWORD: postgres

working_directory: ~/caccs.io

steps:
- checkout

- run:
name: Which bundler?
command: bundle -v

- run:
name: Install environment dependencies
command: sudo apt-get install -y cmake

- restore_cache:
keys:
- v1-dependencies-{{ checksum "Gemfile.lock" }}
- v1-dependencies-

- run:
name: install dependencies
name: Bundle Install
command: bundle check || bundle install --path vendor/bundle

- run:
name: Ruby Lang
command: |
bundle install --jobs=4 --retry=3 --path vendor/bundle
export LANG=C.UTF-8
ruby -e 'puts Encoding.default_external'

- save_cache:
key: v1-dependencies-{{ checksum "Gemfile.lock" }}
paths:
- ./vendor/bundle

# - run:
# name: Wait for DB
# command: dockerize -wait tcp://localhost:5432 -timeout 1m

# Database setup
- run: bundle exec rake db:create
- run: bundle exec rake db:schema:load
- run: bundle exec rake db:schema:load --trace
- run: bundle exec rake db:migrate

# run tests!
- run:
name: run tests
name: Install chrome headless
command: |
mkdir /tmp/test-results
TEST_FILES="$(circleci tests glob "spec/**/*_spec.rb" | circleci tests split --split-by=timings)"

bundle exec rspec --format progress \
--format RspecJunitFormatter \
--out /tmp/test-results/rspec.xml \
--format progress \
$TEST_FILES

# collect reports
- store_test_results:
path: /tmp/test-results
wget -N https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb -P ~/
sudo dpkg -i --force-depends ~/google-chrome-stable_current_amd64.deb
sudo apt-get -f install -y
sudo dpkg -i --force-depends ~/google-chrome-stable_current_amd64.deb
sudo rm /usr/local/bin/chromedriver
wget -N https://chromedriver.storage.googleapis.com/2.25/chromedriver_linux64.zip -P ~/
unzip ~/chromedriver_linux64.zip -d ~/
rm ~/chromedriver_linux64.zip
sudo mv -f ~/chromedriver /usr/local/bin/chromedriver
sudo chown root:root /usr/local/bin/chromedriver
sudo chmod 0755 /usr/local/bin/chromedriver

- type: shell
name: RSpec
command: bundle exec rspec

- run:
name: Pronto
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pronto? ausheuahesae
At least you could use a english word here. hauehuhaes

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shame

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sudoku

command: |
export PRONTO_PULL_REQUEST_ID="$(echo $CIRCLE_PULL_REQUEST | grep -o -E '[0-9]+')"
export PRONTO_GITHUB_SLUG="${CIRCLE_PROJECT_USERNAME}/${CIRCLE_PROJECT_REPONAME}"
export PRONTO_FORMAT="%{msg} [%{runner}:%{level}]"
export PRONTO_VERBOSE=true
bundle exec pronto run -f github_pr github_status -c origin/master

- run:
name: Danger
command: |
bundle exec rake assets:precompile
bundle exec danger

- store_artifacts:
path: /tmp/test-results
destination: test-results
path: tmp/test_results
17 changes: 17 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Faça um resumo breve das alterações as quais você realizou!

## SCREENSHOTS

Tire um tempo para adicionar algumas Screenshots das mudanças!

## TESTES

### CENÁRIOS

Descreva os testes no cenário corretamente

1. Passo 1
2. Passo 2
3. Passo N

Descreva os resultados esperados
30 changes: 28 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,28 @@
/log
/tmp
# See https://help.github.com/articles/ignoring-files for more about ignoring files.
#
# If you find yourself ignoring temporary files generated by your text editor
# or operating system, you probably want to add a global ignore instead:
# git config --global core.excludesfile '~/.gitignore_global'

# Ignore bundler config.
/.bundle

# Ignore all logfiles and tempfiles.
/log/*
/tmp/*
!/log/.keep
!/tmp/.keep

# Ignore uploaded files in development
/storage/*

/node_modules
/yarn-error.log

/public/assets/*
/coverage/
/spec/tmp
.byebug_history

# Ignore master key for decrypting credentials and more.
/config/master.key
4 changes: 4 additions & 0 deletions .pronto.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
all:
exclude:
- 'spec/**/*'
- 'db/migrate/*'
12 changes: 12 additions & 0 deletions Dangerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
message = <<-MESSAGE
## Checklist:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Layout/IndentHeredoc: Use 2 spaces for indentation in a heredoc by using some library(e.g. ActiveSupport's String#strip_heredoc). [rubocop:warning]

- [ ] Run tests locally
- [ ] If you modified some Front files, add ScreenShots!
- [ ] Run tests manually
- [ ] Remove (after you program them) all of your TODOS
- [ ] [Rails Security Checklist](https://github.com/brunofacca/zen-rails-security-checklist)
- [ ] [Rails Style Guide](https://github.com/bbatsov/rails-style-guide)
- [ ] [Ruby Style Guide](https://github.com/bbatsov/ruby-style-guide)
MESSAGE

markdown(message)
9 changes: 9 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FROM postgres
FROM ruby:2.3.6
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs cmake
RUN mkdir /caccs.io
WORKDIR /caccs.io
COPY Gemfile /caccs.io/Gemfile
COPY Gemfile.lock /caccs.io/Gemfile.lock
RUN bundle install
COPY . /caccs.io
60 changes: 43 additions & 17 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,46 +1,72 @@
source 'https://rubygems.org'

git_source(:github) do |repo_name|
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?('/')
"https://github.com/#{repo_name}.git"
end

gem 'bcrypt', '~> 3.1.11'
gem 'bootstrap-sass', '3.3.7'
gem 'rails', '~> 5.1.4'
gem 'puma', '~> 3.7'
gem 'sass-rails', '~> 5.0'
gem 'uglifier', '>= 1.3.0'
gem 'bootstrap3-datetimepicker-rails', '~> 4.17.47'
gem 'coffee-rails', '~> 4.2'
gem 'turbolinks', '~> 5'
gem 'danger'
gem 'danger-github_ext'
gem 'danger-simplecov_json'
gem 'danger-todoist'
gem 'font-awesome-rails'
gem 'fullcalendar-rails'
gem 'jbuilder', '~> 2.5'
gem 'jquery-rails'
gem 'kaminari'
gem 'mailjet'
gem 'parsley-rails'
gem 'font-awesome-rails'
gem 'momentjs-rails'
gem 'fullcalendar-rails'
gem 'bcrypt', '~> 3.1.11'
gem 'kaminari'
gem 'parsley-rails'
gem 'puma', '~> 3.7'
gem 'rails', '~> 5.1.4'
gem 'sass-rails', '~> 5.0'
gem 'turbolinks', '~> 5'
gem 'uglifier', '>= 1.3.0'
gem 'validates_timeliness', '~> 4.0'

group :development, :test do
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
gem 'brakeman'
gem 'byebug', '~> 9.1.0'
gem 'capybara', '~> 2.13'
gem 'selenium-webdriver'
gem 'rspec-rails', '~> 3.7'
gem 'factory_girl_rails', '~> 4.8.0'
gem 'pronto'
gem 'pronto-brakeman'
gem 'pronto-fasterer'
gem 'pronto-flay'
gem 'pronto-rails_best_practices'
gem 'pronto-rails_schema'
gem 'pronto-reek'
gem 'pronto-rubocop'
gem 'pronto-simplecov'
gem 'pry', '~> 0.11.1'
gem 'pry-byebug', '~> 3.5.0'
gem 'rails-controller-testing'
gem 'rails_best_practices'
gem 'reek'
gem 'rspec', '~> 3.7'
gem 'rspec-rails', '~> 3.7'
gem 'rspec_junit_formatter'
gem 'rails-controller-testing'
gem 'rubocop'
gem 'selenium-webdriver'
end

group :development do
gem 'web-console', '>= 3.3.0'
gem 'guard'
gem 'guard-rails'
gem 'guard-rspec'
gem 'guard-rubocop'
gem 'listen', '>= 3.0.5', '< 3.2'
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
gem 'web-console', '>= 3.3.0'
end

group :production do
gem 'pg', '~> 0.20'
end

gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
gem 'tzinfo-data', platforms: %i[mingw mswin x64_mingw jruby]
Loading