Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Jérome Perrin
gitlab-ce
Commits
29c268ee
Commit
29c268ee
authored
May 19, 2017
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Enable RSpec profiling only if RSPEC_PROFILING_POSTGRES_URL is not empty
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
0bce9872
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
config/initializers/rspec_profiling.rb
config/initializers/rspec_profiling.rb
+1
-1
spec/spec_helper.rb
spec/spec_helper.rb
+1
-1
No files found.
config/initializers/rspec_profiling.rb
View file @
29c268ee
...
...
@@ -32,7 +32,7 @@ end
if
Rails
.
env
.
test?
RspecProfiling
.
configure
do
|
config
|
if
ENV
[
'RSPEC_PROFILING_POSTGRES_URL'
]
if
ENV
[
'RSPEC_PROFILING_POSTGRES_URL'
]
.
present?
RspecProfiling
::
Collectors
::
PSQL
.
prepend
(
RspecProfilingExt
::
PSQL
)
config
.
collector
=
RspecProfiling
::
Collectors
::
PSQL
end
...
...
spec/spec_helper.rb
View file @
29c268ee
...
...
@@ -10,7 +10,7 @@ require 'shoulda/matchers'
require
'rspec/retry'
rspec_profiling_is_configured
=
ENV
[
'RSPEC_PROFILING_POSTGRES_URL'
]
||
ENV
[
'RSPEC_PROFILING_POSTGRES_URL'
]
.
present?
||
ENV
[
'RSPEC_PROFILING'
]
branch_can_be_profiled
=
ENV
[
'GITLAB_DATABASE'
]
==
'postgresql'
&&
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment