Skip to content

Commit

Permalink
temp: add asset test script
Browse files Browse the repository at this point in the history
  • Loading branch information
kdmccormick committed Feb 9, 2023
1 parent 0ab841f commit ac7b55f
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test-assets/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
*

!/run.sh
!/.gitignore
33 changes: 33 additions & 0 deletions test-assets/run.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/usr/bin/env bash

set -eou pipefail
set -x

output="test-assets/output_$(date +"%Y-%m-%d_%H-%M-%S")"
mkdir "$output"

test_paths=(
"/openedx/edx-platform"
"/openedx/staticfiles"
"/openedx/static"
"/openedx/themes"
)

test_mode ( ) {
mode="$1"
mkdir "$output/$mode"
for path in "${test_paths[@]}" ; do
tutor "$mode" copyfrom lms "$path" "$output/${mode}${path}"
done
}


tutor config save \
--set EDX_PLATFORM_REPOSITORY=https://github.com/kdmccormick/edx-platform \
--set EDX_PLATFORM_VERSION=kdmccormick/assets-build-sh
tutor images build openedx
tutor dev dc build lms
test_mode local
test_mode dev
#test_mode k8s # TODO

0 comments on commit ac7b55f

Please sign in to comment.