Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/sdf13' into embeddedsdf_refact…
Browse files Browse the repository at this point in the history
…oring
  • Loading branch information
azeey committed Oct 11, 2022
2 parents 332c430 + 3fbdaf7 commit 403dda1
Show file tree
Hide file tree
Showing 47 changed files with 114 additions and 99 deletions.
8 changes: 8 additions & 0 deletions python/test/gz_test_deps/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
This python package encapsulates versioned python packages of gz library
bindings such that the version number only has to be changed in this package.
Here's an example of how to use this in a python test:

```python
from gz_test_deps import math # instead of from gz import math7
from gz_test_deps.math import Vector3d # instead of from gz.math7 import Vector3d
```
Empty file.
1 change: 1 addition & 0 deletions python/test/gz_test_deps/math.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from gz.math7 import *
1 change: 1 addition & 0 deletions python/test/gz_test_deps/sdformat.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from sdformat13 import *
4 changes: 2 additions & 2 deletions python/test/pyAirPressure_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.

from sdformat13 import AirPressure, Noise
import sdformat13 as sdf
from gz_test_deps.sdformat import AirPressure, Noise
import gz_test_deps.sdformat as sdf
import unittest

class AtmosphereTEST(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions python/test/pyAltimeter_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.

from sdformat13 import Altimeter, Noise
import sdformat13 as sdf
from gz_test_deps.sdformat import Altimeter, Noise
import gz_test_deps.sdformat as sdf
import unittest


Expand Down
6 changes: 3 additions & 3 deletions python/test/pyAtmosphere_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
# See the License for the specific language governing permissions and
# limitations under the License.

from gz.math7 import Temperature
from sdformat13 import Atmosphere
import sdformat13 as sdf
from gz_test_deps.math import Temperature
from gz_test_deps.sdformat import Atmosphere
import gz_test_deps.sdformat as sdf
import unittest

class AtmosphereTEST(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions python/test/pyBox_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.

from gz.math7 import Vector3d
from sdformat13 import Box
from gz_test_deps.math import Vector3d
from gz_test_deps.sdformat import Box
import unittest

class BoxTEST(unittest.TestCase):
Expand Down
6 changes: 3 additions & 3 deletions python/test/pyCamera_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
# limitations under the License.

import copy
from gz.math7 import Angle, Pose3d, Vector2d
from gz_test_deps.math import Angle, Pose3d, Vector2d
import math
from sdformat13 import Camera
import sdformat13 as sdf
from gz_test_deps.sdformat import Camera
import gz_test_deps.sdformat as sdf
import unittest

class CameraTEST(unittest.TestCase):
Expand Down
2 changes: 1 addition & 1 deletion python/test/pyCapsule_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import math

from sdformat13 import Capsule
from gz_test_deps.sdformat import Capsule

import unittest

Expand Down
9 changes: 5 additions & 4 deletions python/test/pyCollision_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,11 @@
# limitations under the License.

import copy
from gz.math7 import Pose3d
from sdformat13 import (Box, Collision, Contact, Cylinder, Error, Geometry,
Plane, Surface, Sphere, SDFErrorsException)
import sdformat13 as sdf
from gz_test_deps.math import Pose3d
from gz_test_deps.sdformat import (Box, Collision, Contact, Cylinder, Error,
Geometry, Plane, Surface, Sphere,
SDFErrorsException)
import gz_test_deps.sdformat as sdf
import unittest
import math

Expand Down
2 changes: 1 addition & 1 deletion python/test/pyCylinder_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import math

from sdformat13 import Cylinder
from gz_test_deps.sdformat import Cylinder

import unittest

Expand Down
4 changes: 2 additions & 2 deletions python/test/pyEllipsoid_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
# limitations under the License.

import copy
from gz.math7 import Vector3d
from gz_test_deps.math import Vector3d
import math
from sdformat13 import Ellipsoid
from gz_test_deps.sdformat import Ellipsoid
import unittest


Expand Down
4 changes: 2 additions & 2 deletions python/test/pyError_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import Error
import sdformat13 as sdf
from gz_test_deps.sdformat import Error
import gz_test_deps.sdformat as sdf
import unittest

class ErrorColor(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions python/test/pyForceTorque_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import ForceTorque, Noise
import sdformat13 as sdf
from gz_test_deps.sdformat import ForceTorque, Noise
import gz_test_deps.sdformat as sdf
import unittest

class ForceTorqueTEST(unittest.TestCase):
Expand Down
5 changes: 2 additions & 3 deletions python/test/pyFrame_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.

import copy
from gz.math7 import Pose3d
from sdformat13 import Frame, Error, SDFErrorsException, ErrorCode
from gz_test_deps.math import Pose3d
from gz_test_deps.sdformat import Frame, Error, SDFErrorsException, ErrorCode
import unittest
import math

Expand Down
7 changes: 4 additions & 3 deletions python/test/pyGeometry_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,10 @@
# limitations under the License.

import copy
from sdformat13 import Geometry, Box, Capsule, Cylinder, Ellipsoid, Mesh, Plane, Sphere
from gz.math7 import Vector3d, Vector2d
import sdformat13 as sdf
from gz_test_deps.sdformat import (Geometry, Box, Capsule, Cylinder, Ellipsoid,
Mesh, Plane, Sphere)
from gz_test_deps.math import Vector3d, Vector2d
import gz_test_deps.sdformat as sdf
import unittest


Expand Down
2 changes: 1 addition & 1 deletion python/test/pyGui_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

import copy
from sdformat13 import Gui, Plugin
from gz_test_deps.sdformat import Gui, Plugin
import unittest


Expand Down
4 changes: 2 additions & 2 deletions python/test/pyHeightmap_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from gz.math7 import Vector3d
from sdformat13 import Heightmap, HeightmapBlend, HeightmapTexture
from gz_test_deps.math import Vector3d
from gz_test_deps.sdformat import Heightmap, HeightmapBlend, HeightmapTexture
import unittest


Expand Down
6 changes: 3 additions & 3 deletions python/test/pyIMU_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
# limitations under the License.

import copy
from gz.math7 import Vector3d
from sdformat13 import IMU, Noise
import sdformat13 as sdf
from gz_test_deps.math import Vector3d
from gz_test_deps.sdformat import IMU, Noise
import gz_test_deps.sdformat as sdf
import unittest

class IMUTest(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions python/test/pyJointAxis_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from gz.math7 import Vector3d
from sdformat13 import JointAxis, Error, SDFErrorsException
from gz_test_deps.math import Vector3d
from gz_test_deps.sdformat import JointAxis, Error, SDFErrorsException
import math
import unittest

Expand Down
8 changes: 4 additions & 4 deletions python/test/pyJoint_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
# limitations under the License.

import copy
from gz.math7 import Pose3d, Vector3d
from sdformat13 import (Joint, JointAxis, Error, SemanticPose, Sensor,
SDFErrorsException)
import sdformat13 as sdf
from gz_test_deps.math import Pose3d, Vector3d
from gz_test_deps.sdformat import (Joint, JointAxis, Error, SemanticPose,
Sensor, SDFErrorsException)
import gz_test_deps.sdformat as sdf
import math
import unittest

Expand Down
4 changes: 2 additions & 2 deletions python/test/pyLidar_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from gz.math7 import Angle, Helpers
from sdformat13 import Lidar, Error, Noise
from gz_test_deps.math import Angle, Helpers
from gz_test_deps.sdformat import Lidar, Error, Noise
import math
import unittest

Expand Down
6 changes: 3 additions & 3 deletions python/test/pyLight_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
# limitations under the License.

import copy
from gz.math7 import Angle, Color, Pose3d, Vector3d
from sdformat13 import Light, SDFErrorsException
import sdformat13 as sdf
from gz_test_deps.math import Angle, Color, Pose3d, Vector3d
from gz_test_deps.sdformat import Light, SDFErrorsException
import gz_test_deps.sdformat as sdf
import math
import unittest

Expand Down
6 changes: 3 additions & 3 deletions python/test/pyLink_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
# limitations under the License.

import copy
from gz.math7 import Pose3d, Inertiald, MassMatrix3d, Vector3d
from sdformat13 import (Collision, Light, Link, Sensor, Visual,
SDFErrorsException)
from gz_test_deps.math import Pose3d, Inertiald, MassMatrix3d, Vector3d
from gz_test_deps.sdformat import (Collision, Light, Link, Sensor, Visual,
SDFErrorsException)
import unittest
import math

Expand Down
4 changes: 2 additions & 2 deletions python/test/pyMagnetometer_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import Magnetometer, Noise
import sdformat13 as sdf
from gz_test_deps.sdformat import Magnetometer, Noise
import gz_test_deps.sdformat as sdf
import unittest


Expand Down
6 changes: 3 additions & 3 deletions python/test/pyMaterial_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
# limitations under the License.

import copy
from sdformat13 import Material, Pbr, PbrWorkflow
from gz.math7 import Color
import sdformat13 as sdf
from gz_test_deps.sdformat import Material, Pbr, PbrWorkflow
from gz_test_deps.math import Color
import gz_test_deps.sdformat as sdf
import unittest


Expand Down
4 changes: 2 additions & 2 deletions python/test/pyMesh_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import Mesh
from gz.math7 import Vector3d
from gz_test_deps.sdformat import Mesh
from gz_test_deps.math import Vector3d
import unittest


Expand Down
8 changes: 4 additions & 4 deletions python/test/pyModel_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
# limitations under the License.

import copy
from gz.math7 import Pose3d
from sdformat13 import (Plugin, Model, Joint, Link, Error, Frame, SemanticPose,
SDFErrorsException)
import sdformat13 as sdf
from gz_test_deps.math import Pose3d
from gz_test_deps.sdformat import (Plugin, Model, Joint, Link, Error, Frame,
SemanticPose, SDFErrorsException)
import gz_test_deps.sdformat as sdf
import math
import unittest

Expand Down
2 changes: 1 addition & 1 deletion python/test/pyNavSat_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

import copy
from sdformat13 import NavSat, Noise
from gz_test_deps.sdformat import NavSat, Noise
import unittest

class NavSatColor(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions python/test/pyNoise_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import Noise
import sdformat13 as sdf
from gz_test_deps.sdformat import Noise
import gz_test_deps.sdformat as sdf
import math
import unittest

Expand Down
2 changes: 1 addition & 1 deletion python/test/pyParserConfig_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

import copy
from sdformat13 import ParserConfig
from gz_test_deps.sdformat import ParserConfig
from sdformattest import source_file, test_file
import unittest

Expand Down
4 changes: 2 additions & 2 deletions python/test/pyParticleEmitter_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from gz.math7 import Color, Pose3d, Vector3d, Helpers
from sdformat13 import ParticleEmitter
from gz_test_deps.math import Color, Pose3d, Vector3d, Helpers
from gz_test_deps.sdformat import ParticleEmitter
import unittest


Expand Down
4 changes: 2 additions & 2 deletions python/test/pyPbr_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import Pbr, PbrWorkflow
import sdformat13 as sdf
from gz_test_deps.sdformat import Pbr, PbrWorkflow
import gz_test_deps.sdformat as sdf
import unittest


Expand Down
2 changes: 1 addition & 1 deletion python/test/pyPhysics_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

import copy
from sdformat13 import Physics
from gz_test_deps.sdformat import Physics
import unittest


Expand Down
4 changes: 2 additions & 2 deletions python/test/pyPlane_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.

import copy
from sdformat13 import Plane
from gz.math7 import Vector3d, Vector2d
from gz_test_deps.sdformat import Plane
from gz_test_deps.math import Vector3d, Vector2d
import unittest


Expand Down
2 changes: 1 addition & 1 deletion python/test/pyPlugin_TEST.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

import copy
from sdformat13 import Plugin
from gz_test_deps.sdformat import Plugin
import unittest


Expand Down
Loading

0 comments on commit 403dda1

Please sign in to comment.