canvas 0.58.0__py3-none-any.whl → 0.58.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of canvas might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: canvas
3
- Version: 0.58.0
3
+ Version: 0.58.1
4
4
  Summary: SDK to customize event-driven actions in your Canvas instance
5
5
  Author-email: Canvas Team <engineering@canvasmedical.com>
6
6
  License-Expression: MIT
@@ -71,18 +71,6 @@ canvas_cli/apps/plugin/__init__.py,sha256=GB6hBwbajm5cOs-DbJh3q6smPfAaIMa99tSbkv
71
71
  canvas_cli/apps/plugin/plugin.py,sha256=vlnd61nPt98NnYUPAeZMogcRPgv1pdDqBtey13H_Tug,20817
72
72
  canvas_cli/apps/run_plugins/__init__.py,sha256=iAMgX_6D3CdjQodGx_azwhSjouaxquOm8Z8QVXnlTFE,117
73
73
  canvas_cli/apps/run_plugins/run_plugins.py,sha256=5JbO0l4f2xtJbSTomJgKUqj416sT9GcDF0TrDg2JZYQ,3275
74
- canvas_cli/templates/plugins/application/cookiecutter.json,sha256=cI4Wpj68TkKeBP3P16PrjKacTHzsTIpl_rDdzyUpwz4,129
75
- canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/CANVAS_MANIFEST.json,sha256=-mfqhpljpF4eE8g05pIEnZMt_bDUdhgIBtuQd-devv8,945
76
- canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/README.md,sha256=3QKoJQq3YmdplGnDOBMsLCJ3Ya1_aKjoz-QiWc4QfjA,291
77
- canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/applications/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
78
- canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/applications/my_application.py,sha256=rTUUycVOZEj5B4CoBqWMl9T4xPIyTqxsWGzXfAd6huY,584
79
- canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/assets/python-logo.png,sha256=QAipNLQVwVK_pRO-PpsF3kISrkFUmifyxsjUGzokpNo,20637
80
- canvas_cli/templates/plugins/default/cookiecutter.json,sha256=LbcuMaWxrLats1BffuDkk2192qNTgA-NU6sAnsFyj8M,201
81
- canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/pyproject.toml,sha256=ogQ94GnE-Aj2KJbiTevwnomqKdZUeBZfIOTcU_KPPdI,422
82
- canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/CANVAS_MANIFEST.json,sha256=1keK1aJ-rJu4hm5ypqJT82hooCUTUOQ10dhzQ-mab7c,638
83
- canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/README.md,sha256=3QKoJQq3YmdplGnDOBMsLCJ3Ya1_aKjoz-QiWc4QfjA,291
84
- canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/protocols/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
85
- canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/protocols/my_protocol.py,sha256=fKLLcOIwvSWenW8-7tr8VqnF4Iox_5wU9V-Qw9UySsA,2381
86
74
  canvas_cli/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
87
75
  canvas_cli/utils/context/__init__.py,sha256=HhYvI-hydP0mV18nJiU7uo5gk0yN7EYNgouxieoGDOE,102
88
76
  canvas_cli/utils/context/context.py,sha256=wk4TxlslF52uD9nXcEZ1eY8L1rcEHk7k-6YBVwaWnVY,5191
@@ -322,7 +310,21 @@ protobufs/canvas_generated/messages/plugins.proto,sha256=xJyEeTwM6wWja3vGECLsIzf
322
310
  protobufs/canvas_generated/services/plugin_runner.proto,sha256=PZ0Ts11b9tdA5Gkg2M05JVEKAm0R4LFEwrGRS-TQ16E,466
323
311
  pubsub/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
324
312
  pubsub/pubsub.py,sha256=PHIvJ5SD3M-jQSYeGGSj1FuG6CvP6BQffAoGax9Uudk,1423
325
- canvas-0.58.0.dist-info/METADATA,sha256=QsN4_J0x0w2_4Hg8lQLY6tl2CwWLPgv-8NJzffQH-jg,4758
326
- canvas-0.58.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
327
- canvas-0.58.0.dist-info/entry_points.txt,sha256=0Vs_9GmTVUNniH6eDBlRPgofmADMV4BES6Ao26M4AbM,47
328
- canvas-0.58.0.dist-info/RECORD,,
313
+ canvas_cli/templates/plugins/application/cookiecutter.json,sha256=cI4Wpj68TkKeBP3P16PrjKacTHzsTIpl_rDdzyUpwz4,129
314
+ canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/CANVAS_MANIFEST.json,sha256=-mfqhpljpF4eE8g05pIEnZMt_bDUdhgIBtuQd-devv8,945
315
+ canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/README.md,sha256=3QKoJQq3YmdplGnDOBMsLCJ3Ya1_aKjoz-QiWc4QfjA,291
316
+ canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/applications/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
317
+ canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/applications/my_application.py,sha256=rTUUycVOZEj5B4CoBqWMl9T4xPIyTqxsWGzXfAd6huY,584
318
+ canvas_cli/templates/plugins/application/{{ cookiecutter.__project_slug }}/assets/python-logo.png,sha256=QAipNLQVwVK_pRO-PpsF3kISrkFUmifyxsjUGzokpNo,20637
319
+ canvas_cli/templates/plugins/default/cookiecutter.json,sha256=LbcuMaWxrLats1BffuDkk2192qNTgA-NU6sAnsFyj8M,201
320
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/pyproject.toml,sha256=ogQ94GnE-Aj2KJbiTevwnomqKdZUeBZfIOTcU_KPPdI,422
321
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
322
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/tests/test_models.py,sha256=IWe3IarNQuS350owh87X1qi-PcpaxzBBNCStr8LC3Co,980
323
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/CANVAS_MANIFEST.json,sha256=1keK1aJ-rJu4hm5ypqJT82hooCUTUOQ10dhzQ-mab7c,638
324
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/README.md,sha256=3QKoJQq3YmdplGnDOBMsLCJ3Ya1_aKjoz-QiWc4QfjA,291
325
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/protocols/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
326
+ canvas_cli/templates/plugins/default/{{ cookiecutter.__project_slug }}/{{ cookiecutter.__package_name }}/protocols/my_protocol.py,sha256=fKLLcOIwvSWenW8-7tr8VqnF4Iox_5wU9V-Qw9UySsA,2381
327
+ canvas-0.58.1.dist-info/METADATA,sha256=3X9kEv7rwoBL0FHJVrtoGNhJYPYU_lojLmyJxgVY6n0,4758
328
+ canvas-0.58.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
329
+ canvas-0.58.1.dist-info/entry_points.txt,sha256=0Vs_9GmTVUNniH6eDBlRPgofmADMV4BES6Ao26M4AbM,47
330
+ canvas-0.58.1.dist-info/RECORD,,
@@ -0,0 +1,21 @@
1
+ # To run the tests, use the command `pytest` in the terminal or uv run pytest.
2
+ # Each test is wrapped inside a transaction that is rolled back at the end of the test.
3
+ # If you want to modify which files are used for testing, check the [tool.pytest.ini_options] section in pyproject.toml.
4
+
5
+
6
+ from canvas_sdk.test_utils.factories import PatientFactory
7
+ from canvas_sdk.v1.data.discount import Discount
8
+
9
+
10
+ # You can use a factory to create a patient instance for testing purposes.
11
+ def test_factory() -> None:
12
+ """Test that a patient can be created using the PatientFactory."""
13
+ patient = PatientFactory.create()
14
+ assert patient.id is not None
15
+
16
+
17
+ # if a factory is not available, you can create an instance manually with the data model directly.
18
+ def test_model() -> None:
19
+ """Test that a Discount instance can be created."""
20
+ Discount.objects.create(name="10%", adjustment_group="30", adjustment_code="CO", discount=0.10)
21
+ assert Discount.objects.first().pk is not None