FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
roadmap/.github/workflows/mysql.yml at main · DMPRoadmap/roadmap · GitHub
DMPRoadmap
roadmap
Repository navigation
Code
Issues
300
(300)
Pull requests
49
(49)
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
roadmap
/
.github
/
workflows
/
mysql.yml
Copy path
View runs
More file actions
More file actions
Latest commit
History
History
History
75 lines (59 loc) · 2.31 KB
Breadcrumbs
roadmap
/
.github
/
workflows
/
mysql.yml
Copy path
File metadata and controls
75 lines (59 loc) · 2.31 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name
:
Tests - MySQL
on
:
[pull_request]
jobs
:
mysql
:
runs-on
:
ubuntu-24.04
#
Define environment variables for MySQL and Rails
env
:
DB_ADAPTER
:
mysql2
MYSQL_PWD
:
root
RAILS_ENV
:
test
steps
:
#
Checkout the repo
-
uses
:
actions/checkout@v5
#
Install Ruby and run bundler
-
uses
:
ruby/setup-ruby@v1
with
:
bundler-cache
:
true
#
Install Node
-
uses
:
actions/setup-node@v5
with
:
node-version
:
24
cache
:
'
yarn
'
#
Copy all of the example configs over
-
name
:
'
Setup the application
'
run
:
|
cp config/database.yml.sample config/database.yml
cp config/initializers/contact_us.rb.example config/initializers/contact_us.rb
cp config/initializers/wicked_pdf.rb.example config/initializers/wicked_pdf.rb
cp .env.mysql2 .env
#
Stub out the Rails credentials file so that we can start the Rails app
-
name
:
'
Setup Credentials
'
run
:
EDITOR="sh -c 'echo \"$(cat config/credentials.yml.mysql2)\" > \$1' --" bundle exec rails credentials:edit
#
Set the path to the wkhtmltopdf executable
-
name
:
'
Determine wkhtmltopdf location
'
run
:
echo "WICKED_PDF_PATH=`bundle exec which wkhtmltopdf`" >> $GITHUB_ENV
#
Run yarn install for JS dependencies
-
name
:
'
Yarn Install
'
run
:
yarn install --frozen-lockfile
#
Start the DB server and initialize the DB
-
name
:
'
Start MySQL
'
run
:
sudo systemctl start mysql
-
name
:
'
Build out the test database
'
run
:
|
bundle exec rails db:create RAILS_ENV=test
bundle exec rails db:schema:load RAILS_ENV=test
-
name
:
'
Run any pending database migrations
'
run
:
bin/rails db:migrate RAILS_ENV=test
#
Prebuild the CSS, JS and image assets
-
name
:
'
Precompile all of the Assets
'
run
:
bundle exec rails assets:precompile
#
Run the unit and functional tests
-
name
:
'
Run Rspec Unit and Functional Tests
'
run
:
|
bundle exec rspec spec/models/ spec/policies/ spec/services/ spec/helpers/
bundle exec rspec spec/controllers/ spec/presenters/ spec/requests/ spec/views
bundle exec rspec spec/mixins/
#
Run the time consuming integration tests (using Chrome headless browser)
-
name
:
'
Run Rspec Integration Tests
'
run
:
bundle exec rspec spec/features/
Back
|
FazBrowse Home
|
New Git URL