# How to Create Proper Python Unit Test for DAZL

**URL:** <https://forum.canton.network/t/how-to-create-proper-python-unit-test-for-dazl/4599>\
**Category:** App Development\
**Created:** [May 23, 2022, 11:44pm UTC](https://forum.canton.network/t/how-to-create-proper-python-unit-test-for-dazl/4599 "2022-05-23T23:44:18Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![a\_putkov](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/a_putkov/32/2971_2.png) [@a\_putkov](https://forum.canton.network/u/a_putkov)\
**Post date:** [May 26, 2022, 5:09pm UTC](https://forum.canton.network/t/how-to-create-proper-python-unit-test-for-dazl/4599/4 "2022-05-26T17:09:43Z")

</div>

Housekeeping note: this follow up question is posted on a new thread and is being answered there.

> [@Running DAZL tests in Github Presubmit (Also with bazel)](https://discuss.daml.com/t/running-dazl-tests-in-github-presubmit-also-with-bazel/4608):
>
> Expanding to a new question from: Currently we have a test that runs locally ok. (I manually executed the lines in Setup.daml as conn.upload\_package does not seem to execute the init-script.) However, when I try to run it in github as a presubmit action, it runs into an error like this: with testing.sandbox(project\_root=None, version='2.0.0') as sb: File "BAZEL\_DIRECTORYSTUFF/test.runfiles/pip\_pypi\_\_dazl/dazl/testing/\_sandbox.py", line 126, in \_\_enter\_\_ self.start() File "BAZEL\_D…

---

_[View the full topic](https://forum.canton.network/t/how-to-create-proper-python-unit-test-for-dazl/4599)._
