We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 01e91d8 + dc8b9ac commit 719dd28Copy full SHA for 719dd28
.github/workflows/docs.yml
@@ -17,11 +17,12 @@ jobs:
17
steps:
18
- uses: actions/checkout@v2
19
20
- - uses: compas-dev/compas-actions.docs@v1.3.0
+ - uses: compas-dev/compas-actions.docs@v1.4.1
21
id: docs
22
with:
23
dest: deploy
24
build_to_subfolder: true
25
+ test_docs: true
26
27
- name: Deploy docs
28
if: success() && steps.docs.outputs.commit_type != 'pull'
CHANGELOG.md
@@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
9
10
### Added
11
12
+* Added doc test step in CI/CD.
13
+
14
### Changed
15
16
### Removed
src/compas/datastructures/mesh/matrices.py
@@ -56,8 +56,6 @@ def mesh_adjacency_matrix(mesh, rtype='array'):
56
<class 'numpy.ndarray'>
57
58
>>> A = mesh_adjacency_matrix(mesh, rtype='csr')
59
- >>> type(A)
60
- <class 'scipy.sparse.csr.csr_matrix'>
61
62
"""
63
key_index = mesh.key_index()
@@ -89,8 +87,6 @@ def mesh_connectivity_matrix(mesh, rtype='array'):
89
87
90
88
91
>>> C = mesh_connectivity_matrix(mesh, rtype='csr')
92
- >>> type(C)
93
94
95
>>> xyz = asarray(mesh.vertices_attributes('xyz'))
96
@@ -126,8 +122,6 @@ def mesh_degree_matrix(mesh, rtype='array'):
126
122
127
123
128
124
>>> D = mesh_degree_matrix(mesh, rtype='csr')
129
- >>> type(D)
130
131
125
132
>>> D = mesh_degree_matrix(mesh)
133
>>> D.diagonal()
@@ -181,8 +175,6 @@ def mesh_face_matrix(mesh, rtype='array'):
181
175
182
176
183
177
>>> F = mesh_face_matrix(mesh, rtype='csr')
184
- >>> type(F)
185
186
178
187
179
>>> from numpy import allclose
188
180
@@ -247,8 +239,6 @@ def mesh_laplacian_matrix(mesh, rtype='csr'):
247
239
248
240
249
241
>>> L = mesh_face_matrix(mesh, rtype='csr')
250
- >>> type(L)
251
252
242
253
243
254
244
>>> L = mesh_laplacian_matrix(mesh)
src/compas/geometry/_core/distance.py
@@ -606,13 +606,12 @@ def closest_points_in_cloud_numpy(points, cloud, threshold=10**7, distances=True
606
607
Examples
608
--------
609
+ >>> from numpy import allclose
610
>>> points = [[0, 0, 0], [1, 0, 0], [1, 1, 0], [0, 1, 0]]
611
>>> cloud = [[0, 0, 0], [1, 0, 0], [1, 1, 0], [0, 1, 0]]
- >>> closest_points_in_cloud_numpy(points, cloud, distances=True)
612
- (array([0, 1, 2, 3], dtype=int64), array([[0. , 1. , 1.41421356, 1. ],
613
- [1. , 0. , 1. , 1.41421356],
614
- [1.41421356, 1. , 0. , 1. ],
615
- [1. , 1.41421356, 1. , 0. ]]))
+ >>> cp = closest_points_in_cloud_numpy(points, cloud, distances=True)
+ >>> allclose(cp[1], [[0, 1, 1.4142, 1], [1, 0, 1, 1.4142], [1.4142, 1, 0, 1], [1, 1.4142, 1, 0]])
+ True
616
617
618
from numpy import asarray
src/compas/numerical/linalg.py
@@ -166,8 +166,10 @@ def dof(A, tol=0.001, condition=False):
166
167
168
169
- >>> dof([[2, -1, 3], [1, 0, 1], [0, 2, -1], [1, 1, 4]], condition=True)
170
- (0, 1, 5.073596551276727)
+ >>> d = dof([[2, -1, 3], [1, 0, 1], [0, 2, -1], [1, 1, 4]], condition=True)
171
+ >>> allclose(d, (0, 1, 5.073596551))
172
173
174
A = atleast_2d(asarray(A, dtype=float))
src/compas/rpc/proxy.py
@@ -89,13 +89,13 @@ class Proxy(object):
Minimal example showing connection to the proxy server, and ensuring the
server is disposed after using it:
- >>> from compas.rpc import Proxy
- >>> with Proxy('compas.numerical') as numerical:
- ... pass
- ...
- Starting a new proxy server...
97
- New proxy server started.
98
- Stopping the server proxy.
+ >>> from compas.rpc import Proxy # doctest: +SKIP
+ >>> with Proxy('compas.numerical') as numerical: # doctest: +SKIP
+ ... pass # doctest: +SKIP
+ ... # doctest: +SKIP
+ Starting a new proxy server... # doctest: +SKIP
+ New proxy server started. # doctest: +SKIP
+ Stopping the server proxy. # doctest: +SKIP
99
100
101
def __init__(self, package=None, python=None, url='http://127.0.0.1', port=1753, service=None, max_conn_attempts=100, autoreload=True, capture_output=True):
0 commit comments