Skip to content

Commit

Permalink
Update test.
Browse files Browse the repository at this point in the history
  • Loading branch information
vaxenburg committed Mar 6, 2024
1 parent 85d92c3 commit a09726c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/test_core.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Test core installation by creating an RL environment and stepping it."""

import os
import numpy as np
from flybody.fly_envs import walk_on_ball

Expand All @@ -18,6 +19,7 @@

obs_names = ['walker/' + s for s in obs_names]


def test_can_create_and_run_environment():

env = walk_on_ball()
Expand All @@ -38,3 +40,6 @@ def test_can_create_and_run_environment():
timestep = env.step(action)
assert timestep.reward is not None

# For local testing only.
if os.environ['MUJOCO_GL'] == 'egl':
_ = env.physics.render()

0 comments on commit a09726c

Please sign in to comment.