Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
devstack
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
devstack
Commits
0e3d492b
Commit
0e3d492b
authored
Jul 27, 2017
by
Jeremy Bowman
Committed by
Jeremy Bowman
Aug 09, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PLAT-1590 Add e2e tests container
parent
4672671b
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
51 additions
and
5 deletions
+51
-5
Makefile
+4
-1
README.rst
+16
-0
clone.sh
+1
-0
docker-compose.yml
+6
-4
provision-e2e.sh
+23
-0
provision.sh
+1
-0
No files found.
Makefile
View file @
0e3d492b
.DEFAULT_GOAL
:=
help
DEVSTACK_WORKSPACE
?=
..
DEVSTACK_WORKSPACE
?=
$(
shell
pwd
)
/
..
OS
:=
$(
shell
uname
)
...
...
@@ -82,6 +82,9 @@ restore: ## Restore all data volumes from the host. WARNING: THIS WILL OVERWRIT
credentials-shell
:
##
Run a shell on the credentials container
docker
exec
-it
edx.devstack.credentials env
TERM
=
$(TERM)
bash
e2e-shell
:
##
Start the end-to-end tests container with a shell
docker run
-it
--network
=
devstack_default
-v
${
DEVSTACK_WORKSPACE
}
/edx-e2e-tests:/edx-e2e-tests
-v
${
DEVSTACK_WORKSPACE
}
/edx-platform:/edx-e2e-tests/lib/edx-platform
--env-file
${
DEVSTACK_WORKSPACE
}
/edx-e2e-tests/devstack_env edxops/e2e env
TERM
=
$(TERM)
bash
lms-shell
:
##
Run a shell on the LMS container
docker
exec
-it
edx.devstack.lms env
TERM
=
$(TERM)
/edx/app/edxapp/devstack.sh open
...
...
README.rst
View file @
0e3d492b
...
...
@@ -404,6 +404,21 @@ running ``make vnc-passwords``. To use Chrome for tests that normally
use Firefox instead, prefix the test command with
``SELENIUM_BROWSER=chrome SELENIUM_HOST=edx.devstack.chrome``.
Running End-to-End Tests
------------------------
To run the end-to-end tests for edx-platform, start a shell for the e2e
container and run the tests via paver:
.. code:: sh
make e2e-shell
paver e2e_test --exclude=whitelabel
Additional testing options are available as described in the
`edx-e2e-tests README`_. The browser running the tests can be seen and
interacted with via VNC as described above (Chrome is used by default).
Troubleshooting: General Tips
-----------------------------
...
...
@@ -608,6 +623,7 @@ GitHub issue which explains the `current status of implementing delegated consis
.. _current status of implementing delegated consistency mode: https://github.com/docker/for-mac/issues/1592
.. _configuring Docker for Mac: https://docs.docker.com/docker-for-mac/#/advanced
.. _feature added in Docker 17.05: https://github.com/edx/configuration/pull/3864
.. _edx-e2e-tests README: https://github.com/edx/edx-e2e-tests/#how-to-run-lms-and-studio-tests
.. _edxops Docker image: https://hub.docker.com/r/edxops/
.. _Docker Hub: https://hub.docker.com/
.. _Pycharm Integration documentation: docs/pycharm_integration.rst
...
...
clone.sh
View file @
0e3d492b
...
...
@@ -18,6 +18,7 @@ repos=(
"https://github.com/edx/course-discovery.git"
"https://github.com/edx/credentials.git"
"https://github.com/edx/ecommerce.git"
"https://github.com/edx/edx-e2e-tests.git"
"https://github.com/edx/edx-platform.git"
)
...
...
docker-compose.yml
View file @
0e3d492b
...
...
@@ -18,8 +18,9 @@ services:
shm_size
:
2g
ports
:
-
"
15900:5900"
volumes
:
-
../edx-platform:/edx/app/edxapp/edx-platform
# for file uploads
volumes
:
# for file uploads
-
../edx-e2e-tests/upload_files:/edx/app/e2e/edx-e2e-tests/upload_files
-
../edx-platform/common/test/data:/edx/app/edxapp/edx-platform/common/test/data
elasticsearch
:
container_name
:
edx.devstack.elasticsearch
...
...
@@ -38,8 +39,9 @@ services:
shm_size
:
2g
ports
:
-
"
25900:5900"
volumes
:
-
../edx-platform:/edx/app/edxapp/edx-platform
# for file uploads
volumes
:
# for file uploads
-
../edx-e2e-tests/upload_files:/edx/app/e2e/edx-e2e-tests/upload_files
-
../edx-platform/common/test/data:/edx/app/edxapp/edx-platform/common/test/data
memcached
:
container_name
:
edx.devstack.memcached
...
...
provision-e2e.sh
0 → 100755
View file @
0e3d492b
set
-e
set
-o
pipefail
set
-x
if
[
-z
"
$DEVSTACK_WORKSPACE
"
]
;
then
DEVSTACK_WORKSPACE
=
..
elif
[
!
-d
"
$DEVSTACK_WORKSPACE
"
]
;
then
echo
"Workspace directory
$DEVSTACK_WORKSPACE
doesn't exist"
exit
1
fi
# Copy the test course tarball into the studio container
docker cp
${
DEVSTACK_WORKSPACE
}
/edx-e2e-tests/upload_files/course.tar.gz edx.devstack.studio:/tmp/
# Extract the test course tarball
docker-compose
exec
studio bash
-c
'cd /tmp && tar xzf course.tar.gz'
# Import the course content
docker-compose
exec
studio bash
-c
'source /edx/app/edxapp/edxapp_env && python /edx/app/edxapp/edx-platform/manage.py cms --settings=devstack_docker import /tmp course'
# Clean up the temp files
docker-compose
exec
studio bash
-c
'rm /tmp/course.tar.gz'
docker-compose
exec
studio bash
-c
'rm -r /tmp/course'
provision.sh
View file @
0e3d492b
...
...
@@ -45,6 +45,7 @@ docker-compose $DOCKER_COMPOSE_FILES up -d studio
./provision-ecommerce.sh
./provision-discovery.sh
./provision-credentials.sh
./provision-e2e.sh
docker image prune
-f
...
...
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