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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
5e73bb25
Commit
5e73bb25
authored
Jun 05, 2020
by
Erick Banks
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use let syntax for variables
parent
b8ce03a6
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
15 deletions
+15
-15
qa/qa/specs/features/ee/browser_ui/enablement/elasticsearch/elasticsearch_reindexing_spec.rb
...enablement/elasticsearch/elasticsearch_reindexing_spec.rb
+15
-15
No files found.
qa/qa/specs/features/ee/browser_ui/enablement/elasticsearch/elasticsearch_reindexing_spec.rb
View file @
5e73bb25
...
...
@@ -4,42 +4,42 @@ module QA
context
'Create'
do
describe
'Search using Elasticsearch'
,
:orchestrated
,
:elasticsearch
,
:requires_admin
do
include
Runtime
::
Fixtures
let
(
:project_name
)
{
'testing_elasticsearch_indexing'
}
let
(
:project_file_name
)
{
'elasticsearch.rb'
}
let
(
:project_file_content
)
{
'elasticsearch: true'
}
let
(
:project
)
do
Resource
::
Project
.
fabricate_via_api!
do
|
project
|
project
.
name
=
project_name
end
end
before
do
project_name
=
'testing_elasticsearch_indexing'
@project_file_name
=
'elasticsearch.rb'
@project_file_content
=
'elasticsearch: true'
Flow
::
Login
.
while_signed_in_as_admin
do
QA
::
EE
::
Resource
::
Settings
::
Elasticsearch
.
fabricate_via_browser_ui!
end
Runtime
::
Search
.
assert_elasticsearch_responding
@project
=
Resource
::
Project
.
fabricate_via_api!
do
|
project
|
project
.
name
=
project_name
end
Flow
::
Login
.
sign_in
Resource
::
Repository
::
ProjectPush
.
fabricate!
do
|
push
|
push
.
project
=
@
project
push
.
file_name
=
@
project_file_name
push
.
file_content
=
@
project_file_content
push
.
project
=
project
push
.
file_name
=
project_file_name
push
.
file_content
=
project_file_content
end
.
project
.
visit!
end
it
'tests reindexing after push'
,
retry:
3
do
expect
{
Runtime
::
Search
.
find_code
(
@project_file_name
,
@
project_file_content
)
}.
not_to
raise_error
expect
{
Runtime
::
Search
.
find_code
(
project_file_name
,
project_file_content
)
}.
not_to
raise_error
QA
::
Page
::
Main
::
Menu
.
perform
do
|
menu
|
menu
.
search_for
(
@
project_file_content
)
menu
.
search_for
(
project_file_content
)
end
Page
::
Search
::
Results
.
perform
do
|
search
|
search
.
switch_to_code
expect
(
search
).
to
have_file_with_content
@project_file_name
,
@
project_file_content
expect
(
search
).
to
have_file_with_content
project_file_name
,
project_file_content
end
end
...
...
@@ -69,7 +69,7 @@ module QA
Page
::
Search
::
Results
.
perform
do
|
search
|
search
.
switch_to_code
expect
(
search
).
to
have_file_in_project
template
[
:file_name
],
@
project
.
name
expect
(
search
).
to
have_file_in_project
template
[
:file_name
],
project
.
name
expect
(
search
).
to
have_file_with_content
template
[
:file_name
],
content
[
0
..
33
]
end
end
...
...
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