Skip to content

Commit 5900218

Browse files
authored
Merge pull request #26 from fcollman/develop
releasing new version
2 parents b7e124c + e13123c commit 5900218

File tree

5 files changed

+28
-19
lines changed

5 files changed

+28
-19
lines changed

Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
FROM fcollman/render-python-base:latest
22
MAINTAINER Forrest Collman ([email protected])
33

4-
RUN mkdir -p /usr/local/render-python
5-
COPY . /usr/local/render-python
6-
WORKDIR /usr/local/render-python
7-
RUN python setup.py install
4+
RUN mkdir -p /shared/render-python
5+
COPY . /shared/render-python
6+
RUN pip install -e /shared/render-python
7+
WORKDIR /shared/render-python
88

99
ENTRYPOINT [ "/usr/bin/tini", "--" ]
1010
CMD [ "/bin/bash" ]

integration_tests/test_client_integrated.py

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,12 @@ def test_importTransformChangesClient(render, teststack):
177177
teststack, deststack, TCCjson, changeMode='APPEND', render=render)
178178
renderapi.stack.set_stack_state(deststack, 'COMPLETE', render=render)
179179
os.remove(TCCjson)
180+
181+
output_ts = renderapi.tilespec.get_tile_specs_from_stack(
182+
deststack, render=render)
183+
180184
assert all([ts.tforms[-1].to_dict() == tform_to_append.to_dict()
181-
for ts in renderapi.tilespec.get_tile_specs_from_stack(
182-
deststack, render=render)])
185+
for ts in output_ts])
183186
renderapi.stack.delete_stack(deststack, render=render)
184187

185188

@@ -188,14 +191,19 @@ def test_transformSectionClient(render, teststack,
188191
deststack = 'test_stack_TSC'
189192
transformId = 'TSC_testtransform'
190193
zvalues = renderapi.stack.get_z_values_for_stack(teststack, render=render)
191-
tform = renderapi.transform.AffineModel()
194+
tform = renderapi.transform.AffineModel(transformId=transformId)
192195

193196
renderapi.client.transformSectionClient(
194197
teststack, transformId, tform.className,
195198
tform.dataString.replace(" ", ","), zvalues, targetStack=deststack,
196199
render=render)
197200
renderapi.stack.set_stack_state(deststack, 'COMPLETE', render=render)
201+
202+
output_ts = renderapi.tilespec.get_tile_specs_from_stack(
203+
deststack, render=render)
204+
root.debug(output_ts[0].tforms[-1].to_dict())
205+
root.debug(output_ts[-1].tforms[-1].to_dict())
206+
root.debug(tform.to_dict())
198207
assert all([ts.tforms[-1].to_dict() == tform.to_dict()
199-
for ts in renderapi.tilespec.get_tile_specs_from_stack(
200-
deststack, render=render)])
208+
for ts in output_ts])
201209
renderapi.stack.delete_stack(deststack, render=render)

integration_tests/test_data.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1+
import os
12

2-
render_host = 'renderservice'
3-
render_port = 8080
4-
client_script_location = ('/var/www/render/render-ws-java-client/'
5-
'src/main/scripts/')
6-
tilespec_file = ('/var/www/render/examples/'
7-
'example_1/cycle1_step1_acquire_tiles.json')
8-
tform_file = ('/var/www/render/examples/'
9-
'example_1/cycle1_step1_acquire_transforms.json')
3+
render_host = os.environ.get('RENDER_HOST','renderservice')
4+
render_port = os.environ.get('RENDER_PORT',8080)
5+
client_script_location = os.environ.get('RENDER_CLIENT_SCRIPTS',
6+
('/var/www/render/render-ws-java-client/'
7+
'src/main/scripts/'))
8+
example_dir = os.environ.get('RENDER_EXAMPLE_DATA','/var/www/render/examples/')
9+
tilespec_file = os.path.join(example_dir,'example_1','cycle1_step1_acquire_tiles.json')
10+
tform_file = os.path.join(example_dir,'example_1','cycle1_step1_acquire_transforms.json')

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def run_tests(self):
2929
required = f.read().splitlines()
3030

3131
setup(name='render-python',
32-
version='1.0.1',
32+
version='1.0.2',
3333
description=' a python API to interact via python with render '
3434
'databases see https://github.com/saalfeldlab/render',
3535
author='Forrest Collman, Russel Torres, Eric Perlman, Sharmi Seshamani',

test/test_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,4 +61,4 @@ def test_decorator():
6161
(owner,host,port,project,client_scripts)=my_decorated(5,render=r)
6262
assert(owner == args['owner'])
6363
(owner,host,port,project,client_scripts)=my_decorated(5,owner='newowner',render=r)
64-
assert(owner == 'newowner')
64+
assert(owner == 'newowner')

0 commit comments

Comments
 (0)