mirror of
https://github.com/viewflow/viewflow.git
synced 2026-03-13 10:32:34 +08:00
14 lines
469 B
Python
14 lines
469 B
Python
from django.test import TestCase
|
|
from viewflow.workflow import STATUS
|
|
from viewflow.workflow.models import Process, Task
|
|
from viewflow.workflow.activation import Activation
|
|
|
|
|
|
class Test(TestCase): # noqa: D101
|
|
def test_lifecycle(self):
|
|
process = Process()
|
|
task = Task(process=process, status=STATUS.NEW)
|
|
activation = Activation(task)
|
|
transitions = activation.get_outgoing_transitions()
|
|
self.assertEqual(2, len(transitions))
|