Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
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
edx
edx-platform
Commits
0b8e6bc0
Commit
0b8e6bc0
authored
Oct 27, 2015
by
Jesse Zoldak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adjust circleCI config for parallelism
parent
d39d0cf5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
61 additions
and
45 deletions
+61
-45
scripts/circle-ci-tests.sh
+61
-45
No files found.
scripts/circle-ci-tests.sh
View file @
0b8e6bc0
...
@@ -31,48 +31,64 @@ export NO_PREREQ_INSTALL='true'
...
@@ -31,48 +31,64 @@ export NO_PREREQ_INSTALL='true'
EXIT
=
0
EXIT
=
0
case
$CIRCLE_NODE_INDEX
in
if
[
"
$CIRCLE_NODE_TOTAL
"
==
"1"
]
;
then
0
)
# run the quality metrics
echo
"Only 1 container is being used to run the tests."
echo
"Finding fixme's and storing report..."
echo
"To run in more containers, configure parallelism for this repo's settings "
paver find_fixme
>
fixme.log
||
{
cat
fixme.log
;
EXIT
=
1
;
}
echo
"via the CircleCI UI and adjust scripts/circle-ci-tests.sh to match."
echo
"Finding pep8 violations and storing report..."
echo
"Running tests for common/lib/ and pavelib/"
paver run_pep8
>
pep8.log
||
{
cat
pep8.log
;
EXIT
=
1
;
}
paver test_lib
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
||
EXIT
=
1
echo
"Running python tests for Studio"
echo
"Finding pylint violations and storing in report..."
paver test_system
-s
cms
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
||
EXIT
=
1
# HACK: we need to print something to the console, otherwise circleci
echo
"Running python tests for lms"
# fails and aborts the job because nothing is displayed for > 10 minutes.
paver test_system
-s
lms
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
||
EXIT
=
1
paver run_pylint
-l
$PYLINT_THRESHOLD
| tee pylint.log
||
EXIT
=
1
exit
$EXIT
mkdir
-p
reports
else
echo
"Finding jshint violations and storing report..."
# Split up the tests to run in parallel on 4 containers
PATH
=
$PATH
:node_modules/.bin
case
$CIRCLE_NODE_INDEX
in
paver run_jshint
-l
$JSHINT_THRESHOLD
>
jshint.log
||
{
cat
jshint.log
;
EXIT
=
1
;
}
0
)
# run the quality metrics
echo
"Finding fixme's and storing report..."
# Run quality task. Pass in the 'fail-under' percentage to diff-quality
paver find_fixme
>
fixme.log
||
{
cat
fixme.log
;
EXIT
=
1
;
}
paver run_quality
-p
100
||
EXIT
=
1
echo
"Finding pep8 violations and storing report..."
echo
"Running code complexity report (python)."
paver run_pep8
>
pep8.log
||
{
cat
pep8.log
;
EXIT
=
1
;
}
paver run_complexity
>
reports/code_complexity.log
||
echo
"Unable to calculate code complexity. Ignoring error."
echo
"Finding pylint violations and storing in report..."
exit
$EXIT
# HACK: we need to print something to the console, otherwise circleci
;;
# fails and aborts the job because nothing is displayed for > 10 minutes.
paver run_pylint
-l
$PYLINT_THRESHOLD
| tee pylint.log
||
EXIT
=
1
1
)
# run all of the lms unit tests
paver test_system
-s
lms
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
mkdir
-p
reports
;;
echo
"Finding jshint violations and storing report..."
PATH
=
$PATH
:node_modules/.bin
2
)
# run all of the cms unit tests
paver run_jshint
-l
$JSHINT_THRESHOLD
>
jshint.log
||
{
cat
jshint.log
;
EXIT
=
1
;
}
paver test_system
-s
cms
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
;;
# Run quality task. Pass in the 'fail-under' percentage to diff-quality
paver run_quality
-p
100
||
EXIT
=
1
3
)
# run the commonlib unit tests
paver test_lib
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
echo
"Running code complexity report (python)."
;;
paver run_complexity
>
reports/code_complexity.log
||
echo
"Unable to calculate code complexity. Ignoring error."
*
)
exit
$EXIT
echo
"No tests were executed in this container."
;;
echo
"Please adjust scripts/circle-ci-tests.sh to match your parallelism."
exit
1
1
)
# run all of the lms unit tests
;;
paver test_system
-s
lms
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
esac
;;
2
)
# run all of the cms unit tests
paver test_system
-s
cms
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
;;
3
)
# run the commonlib unit tests
paver test_lib
--extra_args
=
"--with-flaky"
--cov_args
=
"-p"
;;
*
)
echo
"No tests were executed in this container."
echo
"Please adjust scripts/circle-ci-tests.sh to match your parallelism."
exit
1
;;
esac
fi
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