Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
project
drupal
Commits
8aef9a84
Unverified
Commit
8aef9a84
authored
Jun 01, 2018
by
alexpott
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue
#2976593
by drpal, justafish, dawehner: Prefix Nightwatch commands with a "drupal" namespace
parent
8f6fcbdd
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
9 deletions
+9
-9
core/tests/Drupal/Nightwatch/Commands/drupalInstall.js
core/tests/Drupal/Nightwatch/Commands/drupalInstall.js
+1
-1
core/tests/Drupal/Nightwatch/Commands/drupalLogAndEnd.js
core/tests/Drupal/Nightwatch/Commands/drupalLogAndEnd.js
+1
-1
core/tests/Drupal/Nightwatch/Commands/drupalRelativeURL.js
core/tests/Drupal/Nightwatch/Commands/drupalRelativeURL.js
+1
-1
core/tests/Drupal/Nightwatch/Commands/drupalUninstall.js
core/tests/Drupal/Nightwatch/Commands/drupalUninstall.js
+1
-1
core/tests/Drupal/Nightwatch/Tests/exampleTest.js
core/tests/Drupal/Nightwatch/Tests/exampleTest.js
+5
-5
No files found.
core/tests/Drupal/Nightwatch/Commands/
installDrupa
l.js
→
core/tests/Drupal/Nightwatch/Commands/
drupalInstal
l.js
View file @
8aef9a84
...
@@ -14,7 +14,7 @@ import { commandAsWebserver } from '../globals';
...
@@ -14,7 +14,7 @@ import { commandAsWebserver } from '../globals';
* @return {object}
* @return {object}
* The 'browser' object.
* The 'browser' object.
*/
*/
exports
.
command
=
function
installDrupa
l
({
setupFile
=
''
},
callback
)
{
exports
.
command
=
function
drupalInstal
l
({
setupFile
=
''
},
callback
)
{
const
self
=
this
;
const
self
=
this
;
try
{
try
{
...
...
core/tests/Drupal/Nightwatch/Commands/
l
ogAndEnd.js
→
core/tests/Drupal/Nightwatch/Commands/
drupalL
ogAndEnd.js
View file @
8aef9a84
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
* @return {object}
* @return {object}
* The 'browser' object.
* The 'browser' object.
*/
*/
exports
.
command
=
function
l
ogAndEnd
({
onlyOnError
=
true
},
callback
)
{
exports
.
command
=
function
drupalL
ogAndEnd
({
onlyOnError
=
true
},
callback
)
{
const
self
=
this
;
const
self
=
this
;
this
.
drupalLogConsole
=
true
;
this
.
drupalLogConsole
=
true
;
this
.
drupalLogConsoleOnlyOnError
=
onlyOnError
;
this
.
drupalLogConsoleOnlyOnError
=
onlyOnError
;
...
...
core/tests/Drupal/Nightwatch/Commands/
r
elativeURL.js
→
core/tests/Drupal/Nightwatch/Commands/
drupalR
elativeURL.js
View file @
8aef9a84
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
* @return {object}
* @return {object}
* The 'browser' object.
* The 'browser' object.
*/
*/
exports
.
command
=
function
r
elativeURL
(
pathname
,
callback
)
{
exports
.
command
=
function
drupalR
elativeURL
(
pathname
,
callback
)
{
const
self
=
this
;
const
self
=
this
;
this
.
url
(
`
${
process
.
env
.
DRUPAL_TEST_BASE_URL
}${
pathname
}
`
);
this
.
url
(
`
${
process
.
env
.
DRUPAL_TEST_BASE_URL
}${
pathname
}
`
);
...
...
core/tests/Drupal/Nightwatch/Commands/
u
ninstall
Drupal
.js
→
core/tests/Drupal/Nightwatch/Commands/
drupalU
ninstall.js
View file @
8aef9a84
...
@@ -9,7 +9,7 @@ import { commandAsWebserver } from '../globals';
...
@@ -9,7 +9,7 @@ import { commandAsWebserver } from '../globals';
* @return {object}
* @return {object}
* The 'browser' object.
* The 'browser' object.
*/
*/
exports
.
command
=
function
uninstallDrup
al
(
callback
)
{
exports
.
command
=
function
drupalUninst
al
(
callback
)
{
const
self
=
this
;
const
self
=
this
;
const
prefix
=
self
.
drupalDbPrefix
;
const
prefix
=
self
.
drupalDbPrefix
;
...
...
core/tests/Drupal/Nightwatch/Tests/exampleTest.js
View file @
8aef9a84
...
@@ -2,18 +2,18 @@ module.exports = {
...
@@ -2,18 +2,18 @@ module.exports = {
'
@tags
'
:
[
'
core
'
],
'
@tags
'
:
[
'
core
'
],
before
(
browser
)
{
before
(
browser
)
{
browser
browser
.
installDrupa
l
({
setupFile
:
'
core/tests/Drupal/TestSite/TestSiteInstallTestScript.php
'
});
.
drupalInstal
l
({
setupFile
:
'
core/tests/Drupal/TestSite/TestSiteInstallTestScript.php
'
});
},
},
after
(
browser
)
{
after
(
browser
)
{
browser
browser
.
u
ninstall
Drupal
();
.
drupalU
ninstall
();
},
},
'
Test page
'
:
(
browser
)
=>
{
'
Test page
'
:
(
browser
)
=>
{
browser
browser
.
r
elativeURL
(
'
/test-page
'
)
.
drupalR
elativeURL
(
'
/test-page
'
)
.
waitForElementVisible
(
'
body
'
,
1000
)
.
waitForElementVisible
(
'
body
'
,
1000
)
.
assert
.
containsText
(
'
body
'
,
'
Test page text
'
)
.
assert
.
containsText
(
'
body
'
,
'
Test page text
'
)
.
l
ogAndEnd
({
onlyOnError
:
false
});
.
drupalL
ogAndEnd
({
onlyOnError
:
false
});
},
},
/**
/**
'Example failing test': (browser) => {
'Example failing test': (browser) => {
...
@@ -25,7 +25,7 @@ module.exports = {
...
@@ -25,7 +25,7 @@ module.exports = {
// Wait for some errors to build up.
// Wait for some errors to build up.
.pause(5000)
.pause(5000)
.assert.containsText('h1', 'I\'m the operator with my pocket calculator')
.assert.containsText('h1', 'I\'m the operator with my pocket calculator')
.
l
ogAndEnd();
.
drupalL
ogAndEnd();
},
},
**/
**/
};
};
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