Skip to content

Commit

Permalink
New style tests closes mdolab#44 (mdolab#47)
Browse files Browse the repository at this point in the history
Co-authored-by: Josh Anibal <joanibal@umich.edu>
Co-authored-by: Josh Anibal <joanibal+github@umich.edu>
  • Loading branch information
3 people authored Oct 27, 2020
1 parent f7b1164 commit 9cdaff3
Show file tree
Hide file tree
Showing 73 changed files with 219,305 additions and 809,491 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ env:
- DOCKER_REPO=public

install:
- docker exec -it app /bin/bash -c ". $BASHRC && cd $DOCKER_WORKING_DIR && pip install ."
- docker exec -it app /bin/bash -c ". $BASHRC && cd $DOCKER_WORKING_DIR && pip install .[testing] "

script:
- |
if [[ "$TEST_TYPE" == "docker" ]]; then
# run tests
docker exec -it app /bin/bash -c ". $BASHRC && cd $DOCKER_WORKING_DIR/reg_tests && python run_reg_tests.py -nodiff"
docker exec -it app /bin/bash -c ". $BASHRC && cd $DOCKER_WORKING_DIR/tests && testflo . -v -n 1"
fi
after_script:
Expand Down
8 changes: 4 additions & 4 deletions pygeo/DVConstraints.py
Original file line number Diff line number Diff line change
Expand Up @@ -1412,7 +1412,7 @@ def addCompositeVolumeConstraint(self, vols, lower=1.0, upper=3.0,
volCons = []
for vol in vols:
try:
volCons.append(self.volumeCon[vol])
volCons.append(self.constraints[typeName][vol])
except KeyError:
raise Error("The supplied volume name '%s' has not"
" already been added with a call to "
Expand Down Expand Up @@ -2047,7 +2047,7 @@ def addProjectedAreaConstraint(self, axis='y', lower=1.0, upper=3.0, scaled=True

# Create a name
if name is None:
conName = 'projectedArea_constraints_%d'% len(self.constraints[typeName])
conName = '%s_projectedArea_constraints_%d'%(self.name, len(self.constraints[typeName]))
else:
conName = name
self.constraints[typeName][conName] = ProjectedAreaConstraint(
Expand Down Expand Up @@ -2138,10 +2138,10 @@ def addColinearityConstraint(self, origin, lineAxis, distances,
Parameters
----------
origin: vector
The coordinate of the origin
The coordinate of the origin (3x numpy array)
lineAxis: vector
The line of colinearity
The line of colinearity (3x numpy array)
distances: list
List of distances from origin to constrain
Expand Down
8 changes: 5 additions & 3 deletions pygeo/DVGeometry.py
Original file line number Diff line number Diff line change
Expand Up @@ -2980,9 +2980,11 @@ def _sectionlocalDVJacobian(self, config=None):
inFrame[dv.axis] = 1.0

R = numpy.real(self.coefRotM[coef])
rows = range(coef*3,(coef+1)*3)
Jacobian[rows, iDVSectionLocal] += R.dot(T.dot(inFrame))

# this is a bug fix for scipy 1.3+ related to fancy indexing
# the original was:
# rows = range(coef*3,(coef+1)*3)
# Jacobian[rows, iDVSectionLocal] += R.dot(T.dot(inFrame))
Jacobian[coef*3:(coef+1)*3, iDVSectionLocal] += R.dot(T.dot(inFrame))
for iChild in range(len(self.children)):

dXrefdCoef = self.FFD.embededVolumes['child%d_axis'%(iChild)].dPtdCoef
Expand Down
6 changes: 0 additions & 6 deletions reg_tests/inputFiles/axiTestFFD.xyz

This file was deleted.

49 changes: 0 additions & 49 deletions reg_tests/inputFiles/bodyFFD.xyz

This file was deleted.

156 changes: 0 additions & 156 deletions reg_tests/inputFiles/generateFFD.py

This file was deleted.

Loading

0 comments on commit 9cdaff3

Please sign in to comment.