Открыть боковую панель
nt_test132
nt_project_7gohtg18g8li
Коммиты
fe5da23b
Коммит
fe5da23b
создал
Май 02, 2019
по автору
sarahghp
Просмотр файлов
Add initial test
владелец
29990e5a
Изменения
1
Скрыть пробелы
Построчно
Рядом
spec/features/review_app/user_loads_toolbar_spec.rb
Просмотр файла @
fe5da23b
...
...
@@ -3,11 +3,28 @@
describe
'Toolbar'
,
:js
do
describe
'injected toolbar'
do
add_script
=
%q(
const scriptEl = document.createElement('script');
scriptEl.setAttribute('src', 'https://host-island.sarahghp.now.sh/review-toolbar.js');
scriptEl.setAttribute('data-project' , '11790219');
scriptEl.setAttribute('data-discussion' , '1');
scriptEl.setAttribute('data-name' , 'ReviewAppToolbar');
scriptEl.setAttribute('data-mr-url' , 'https://gitlab.com');
document.head.appendChild(scriptEl);
)
load_script
=
%q(
const newLoad = new Event('load');
window.dispatchEvent(newLoad);
)
it
'loads the login screen'
do
visit
root_path
find
(
'body'
)
evaluate_script
(
"document.body.innerHTML = 'hi winnie and sarah, but for real'"
)
live_debug
evaluate_script
(
add_script
)
evaluate_script
(
load_script
)
expect
(
find
(
'#gitlab-review-container'
)).
to
exist
end
end
end
Редактирование
Предварительный просмотр
Поддерживает Markdown
0%
Попробовать снова
или
прикрепить новый файл
.
Отмена
You are about to add
0
people
to the discussion. Proceed with caution.
Сначала завершите редактирование этого сообщения!
Отмена
Пожалуйста,
зарегистрируйтесь
или
войдите
чтобы прокомментировать