ax25sdl 0.1.0

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.
Files changed (58) hide show
  1. package/README.md +59 -0
  2. package/dist/ax25sdl/awaiting_connection.g.d.ts +7 -0
  3. package/dist/ax25sdl/awaiting_connection.g.d.ts.map +1 -0
  4. package/dist/ax25sdl/awaiting_connection.g.js +427 -0
  5. package/dist/ax25sdl/awaiting_connection.g.js.map +1 -0
  6. package/dist/ax25sdl/awaiting_connection.g.test.d.ts +2 -0
  7. package/dist/ax25sdl/awaiting_connection.g.test.d.ts.map +1 -0
  8. package/dist/ax25sdl/awaiting_connection.g.test.js +345 -0
  9. package/dist/ax25sdl/awaiting_connection.g.test.js.map +1 -0
  10. package/dist/ax25sdl/awaiting_release.g.d.ts +7 -0
  11. package/dist/ax25sdl/awaiting_release.g.d.ts.map +1 -0
  12. package/dist/ax25sdl/awaiting_release.g.js +344 -0
  13. package/dist/ax25sdl/awaiting_release.g.js.map +1 -0
  14. package/dist/ax25sdl/awaiting_release.g.test.d.ts +2 -0
  15. package/dist/ax25sdl/awaiting_release.g.test.d.ts.map +1 -0
  16. package/dist/ax25sdl/awaiting_release.g.test.js +255 -0
  17. package/dist/ax25sdl/awaiting_release.g.test.js.map +1 -0
  18. package/dist/ax25sdl/awaiting_v22_connection.g.d.ts +7 -0
  19. package/dist/ax25sdl/awaiting_v22_connection.g.d.ts.map +1 -0
  20. package/dist/ax25sdl/awaiting_v22_connection.g.js +428 -0
  21. package/dist/ax25sdl/awaiting_v22_connection.g.js.map +1 -0
  22. package/dist/ax25sdl/awaiting_v22_connection.g.test.d.ts +2 -0
  23. package/dist/ax25sdl/awaiting_v22_connection.g.test.d.ts.map +1 -0
  24. package/dist/ax25sdl/awaiting_v22_connection.g.test.js +372 -0
  25. package/dist/ax25sdl/awaiting_v22_connection.g.test.js.map +1 -0
  26. package/dist/ax25sdl/connected.g.d.ts +7 -0
  27. package/dist/ax25sdl/connected.g.d.ts.map +1 -0
  28. package/dist/ax25sdl/connected.g.js +1456 -0
  29. package/dist/ax25sdl/connected.g.js.map +1 -0
  30. package/dist/ax25sdl/connected.g.test.d.ts +2 -0
  31. package/dist/ax25sdl/connected.g.test.d.ts.map +1 -0
  32. package/dist/ax25sdl/connected.g.test.js +1313 -0
  33. package/dist/ax25sdl/connected.g.test.js.map +1 -0
  34. package/dist/ax25sdl/disconnected.g.d.ts +7 -0
  35. package/dist/ax25sdl/disconnected.g.d.ts.map +1 -0
  36. package/dist/ax25sdl/disconnected.g.js +340 -0
  37. package/dist/ax25sdl/disconnected.g.js.map +1 -0
  38. package/dist/ax25sdl/disconnected.g.test.d.ts +2 -0
  39. package/dist/ax25sdl/disconnected.g.test.d.ts.map +1 -0
  40. package/dist/ax25sdl/disconnected.g.test.js +266 -0
  41. package/dist/ax25sdl/disconnected.g.test.js.map +1 -0
  42. package/dist/ax25sdl/index.d.ts +8 -0
  43. package/dist/ax25sdl/index.d.ts.map +1 -0
  44. package/dist/ax25sdl/index.js +10 -0
  45. package/dist/ax25sdl/index.js.map +1 -0
  46. package/dist/ax25sdl/sdl.test.d.ts +2 -0
  47. package/dist/ax25sdl/sdl.test.d.ts.map +1 -0
  48. package/dist/ax25sdl/sdl.test.js +47 -0
  49. package/dist/ax25sdl/sdl.test.js.map +1 -0
  50. package/dist/ax25sdl/subroutines.g.d.ts +7 -0
  51. package/dist/ax25sdl/subroutines.g.d.ts.map +1 -0
  52. package/dist/ax25sdl/subroutines.g.js +497 -0
  53. package/dist/ax25sdl/subroutines.g.js.map +1 -0
  54. package/dist/ax25sdl/types.d.ts +94 -0
  55. package/dist/ax25sdl/types.d.ts.map +1 -0
  56. package/dist/ax25sdl/types.js +10 -0
  57. package/dist/ax25sdl/types.js.map +1 -0
  58. package/package.json +46 -0
@@ -0,0 +1,1313 @@
1
+ // Code generated by tools/Packet.Sdl.CodeGen from spec-sdl/data-link/connected.sdl.yaml.
2
+ // DO NOT EDIT. Run `dotnet run --project tools/Packet.Sdl.CodeGen` to regenerate.
3
+ import { describe, it, expect } from "vitest";
4
+ import { DataLinkConnected } from "./connected.g.js";
5
+ describe("DataLinkConnected", () => {
6
+ it("source figure", () => {
7
+ expect(DataLinkConnected.source.figure).toBe("figc4.4");
8
+ });
9
+ it("transitions are present", () => {
10
+ expect(DataLinkConnected.transitions).toHaveLength(69);
11
+ });
12
+ it("t01_dl_disconnect_request", () => {
13
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t01_dl_disconnect_request");
14
+ expect(t, "transition t01_dl_disconnect_request not found").toBeDefined();
15
+ if (!t)
16
+ return;
17
+ expect(t.on).toBe("DL_DISCONNECT_request");
18
+ expect(t.next).toBe("AwaitingRelease");
19
+ expect(t.actions).toHaveLength(5);
20
+ expect(t.actions[0].verb).toBe("discard_I_frame_queue");
21
+ expect(t.actions[0].kind).toBe("processing");
22
+ expect(t.actions[1].verb).toBe("RC := 0");
23
+ expect(t.actions[1].kind).toBe("processing");
24
+ expect(t.actions[2].verb).toBe("DISC (P = 1)");
25
+ expect(t.actions[2].kind).toBe("signal_lower");
26
+ expect(t.actions[3].verb).toBe("stop_T3");
27
+ expect(t.actions[3].kind).toBe("processing");
28
+ expect(t.actions[4].verb).toBe("start_T1");
29
+ expect(t.actions[4].kind).toBe("processing");
30
+ });
31
+ it("t02_i_received_not_command", () => {
32
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t02_i_received_not_command");
33
+ expect(t, "transition t02_i_received_not_command not found").toBeDefined();
34
+ if (!t)
35
+ return;
36
+ expect(t.on).toBe("I_received");
37
+ expect(t.next).toBe("Connected");
38
+ expect(t.guard).toBe("not command");
39
+ expect(t.actions).toHaveLength(2);
40
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_O");
41
+ expect(t.actions[0].kind).toBe("signal_upper");
42
+ expect(t.actions[1].verb).toBe("discard_I_frame");
43
+ expect(t.actions[1].kind).toBe("processing");
44
+ });
45
+ it("t03_i_received_command_info_field_invalid_v22", () => {
46
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t03_i_received_command_info_field_invalid_v22");
47
+ expect(t, "transition t03_i_received_command_info_field_invalid_v22 not found").toBeDefined();
48
+ if (!t)
49
+ return;
50
+ expect(t.on).toBe("I_received");
51
+ expect(t.next).toBe("AwaitingConnection22");
52
+ expect(t.guard).toBe("command and not info_field_valid and version_2_2");
53
+ expect(t.actions).toHaveLength(3);
54
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_O");
55
+ expect(t.actions[0].kind).toBe("signal_upper");
56
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
57
+ expect(t.actions[1].kind).toBe("subroutine");
58
+ expect(t.actions[2].verb).toBe("clear_layer_3_initiated");
59
+ expect(t.actions[2].kind).toBe("processing");
60
+ });
61
+ it("t04_i_received_command_info_field_invalid_v20", () => {
62
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t04_i_received_command_info_field_invalid_v20");
63
+ expect(t, "transition t04_i_received_command_info_field_invalid_v20 not found").toBeDefined();
64
+ if (!t)
65
+ return;
66
+ expect(t.on).toBe("I_received");
67
+ expect(t.next).toBe("AwaitingConnection");
68
+ expect(t.guard).toBe("command and not info_field_valid and not version_2_2");
69
+ expect(t.actions).toHaveLength(3);
70
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_O");
71
+ expect(t.actions[0].kind).toBe("signal_upper");
72
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
73
+ expect(t.actions[1].kind).toBe("subroutine");
74
+ expect(t.actions[2].verb).toBe("clear_layer_3_initiated");
75
+ expect(t.actions[2].kind).toBe("processing");
76
+ });
77
+ it("t05_i_received_command_info_valid_nr_out_of_window_v22", () => {
78
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t05_i_received_command_info_valid_nr_out_of_window_v22");
79
+ expect(t, "transition t05_i_received_command_info_valid_nr_out_of_window_v22 not found").toBeDefined();
80
+ if (!t)
81
+ return;
82
+ expect(t.on).toBe("I_received");
83
+ expect(t.next).toBe("AwaitingConnection22");
84
+ expect(t.guard).toBe("command and info_field_valid and not V_a_le_N_r_le_V_s and version_2_2");
85
+ expect(t.actions).toHaveLength(1);
86
+ expect(t.actions[0].verb).toBe("N_r_Error_Recovery");
87
+ expect(t.actions[0].kind).toBe("subroutine");
88
+ });
89
+ it("t06_i_received_command_info_valid_nr_out_of_window_v20", () => {
90
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t06_i_received_command_info_valid_nr_out_of_window_v20");
91
+ expect(t, "transition t06_i_received_command_info_valid_nr_out_of_window_v20 not found").toBeDefined();
92
+ if (!t)
93
+ return;
94
+ expect(t.on).toBe("I_received");
95
+ expect(t.next).toBe("AwaitingConnection");
96
+ expect(t.guard).toBe("command and info_field_valid and not V_a_le_N_r_le_V_s and not version_2_2");
97
+ expect(t.actions).toHaveLength(1);
98
+ expect(t.actions[0].verb).toBe("N_r_Error_Recovery");
99
+ expect(t.actions[0].kind).toBe("subroutine");
100
+ });
101
+ it("t07_i_received_own_busy_p_eq_1", () => {
102
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t07_i_received_own_busy_p_eq_1");
103
+ expect(t, "transition t07_i_received_own_busy_p_eq_1 not found").toBeDefined();
104
+ if (!t)
105
+ return;
106
+ expect(t.on).toBe("I_received");
107
+ expect(t.next).toBe("Connected");
108
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and own_receiver_busy and P_eq_1");
109
+ expect(t.actions).toHaveLength(6);
110
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
111
+ expect(t.actions[0].kind).toBe("subroutine");
112
+ expect(t.actions[1].verb).toBe("discard_contents_of_I_frame");
113
+ expect(t.actions[1].kind).toBe("processing");
114
+ expect(t.actions[2].verb).toBe("F := 1");
115
+ expect(t.actions[2].kind).toBe("processing");
116
+ expect(t.actions[3].verb).toBe("N(r) := V(r)");
117
+ expect(t.actions[3].kind).toBe("processing");
118
+ expect(t.actions[4].verb).toBe("RR");
119
+ expect(t.actions[4].kind).toBe("signal_lower");
120
+ expect(t.actions[5].verb).toBe("clear_acknowledge_pending");
121
+ expect(t.actions[5].kind).toBe("processing");
122
+ });
123
+ it("t08_i_received_own_busy_p_eq_0", () => {
124
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t08_i_received_own_busy_p_eq_0");
125
+ expect(t, "transition t08_i_received_own_busy_p_eq_0 not found").toBeDefined();
126
+ if (!t)
127
+ return;
128
+ expect(t.on).toBe("I_received");
129
+ expect(t.next).toBe("Connected");
130
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and own_receiver_busy and not P_eq_1");
131
+ expect(t.actions).toHaveLength(2);
132
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
133
+ expect(t.actions[0].kind).toBe("subroutine");
134
+ expect(t.actions[1].verb).toBe("discard_contents_of_I_frame");
135
+ expect(t.actions[1].kind).toBe("processing");
136
+ });
137
+ it("t09_i_received_in_seq_no_stored_p_eq_1", () => {
138
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t09_i_received_in_seq_no_stored_p_eq_1");
139
+ expect(t, "transition t09_i_received_in_seq_no_stored_p_eq_1 not found").toBeDefined();
140
+ if (!t)
141
+ return;
142
+ expect(t.on).toBe("I_received");
143
+ expect(t.next).toBe("Connected");
144
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and N_s_eq_V_r and not V_r_I_frame_stored and P_eq_1");
145
+ expect(t.actions).toHaveLength(9);
146
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
147
+ expect(t.actions[0].kind).toBe("subroutine");
148
+ expect(t.actions[1].verb).toBe("V(r) := V(r) + 1");
149
+ expect(t.actions[1].kind).toBe("processing");
150
+ expect(t.actions[2].verb).toBe("clear_reject_exception");
151
+ expect(t.actions[2].kind).toBe("processing");
152
+ expect(t.actions[3].verb).toBe("decrement_srej_exception_if_gt_0");
153
+ expect(t.actions[3].kind).toBe("processing");
154
+ expect(t.actions[4].verb).toBe("DL_DATA_indication");
155
+ expect(t.actions[4].kind).toBe("signal_upper");
156
+ expect(t.actions[5].verb).toBe("F := 1");
157
+ expect(t.actions[5].kind).toBe("processing");
158
+ expect(t.actions[6].verb).toBe("N(r) := V(r)");
159
+ expect(t.actions[6].kind).toBe("processing");
160
+ expect(t.actions[7].verb).toBe("RR");
161
+ expect(t.actions[7].kind).toBe("signal_lower");
162
+ expect(t.actions[8].verb).toBe("clear_acknowledge_pending");
163
+ expect(t.actions[8].kind).toBe("processing");
164
+ });
165
+ it("t10_i_received_in_seq_no_stored_p_eq_0_ack_pending", () => {
166
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t10_i_received_in_seq_no_stored_p_eq_0_ack_pending");
167
+ expect(t, "transition t10_i_received_in_seq_no_stored_p_eq_0_ack_pending not found").toBeDefined();
168
+ if (!t)
169
+ return;
170
+ expect(t.on).toBe("I_received");
171
+ expect(t.next).toBe("Connected");
172
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and N_s_eq_V_r and not V_r_I_frame_stored and not P_eq_1 and acknowledge_pending");
173
+ expect(t.actions).toHaveLength(5);
174
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
175
+ expect(t.actions[0].kind).toBe("subroutine");
176
+ expect(t.actions[1].verb).toBe("V(r) := V(r) + 1");
177
+ expect(t.actions[1].kind).toBe("processing");
178
+ expect(t.actions[2].verb).toBe("clear_reject_exception");
179
+ expect(t.actions[2].kind).toBe("processing");
180
+ expect(t.actions[3].verb).toBe("decrement_srej_exception_if_gt_0");
181
+ expect(t.actions[3].kind).toBe("processing");
182
+ expect(t.actions[4].verb).toBe("DL_DATA_indication");
183
+ expect(t.actions[4].kind).toBe("signal_upper");
184
+ });
185
+ it("t11_i_received_in_seq_no_stored_p_eq_0_no_ack_pending", () => {
186
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t11_i_received_in_seq_no_stored_p_eq_0_no_ack_pending");
187
+ expect(t, "transition t11_i_received_in_seq_no_stored_p_eq_0_no_ack_pending not found").toBeDefined();
188
+ if (!t)
189
+ return;
190
+ expect(t.on).toBe("I_received");
191
+ expect(t.next).toBe("Connected");
192
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and N_s_eq_V_r and not V_r_I_frame_stored and not P_eq_1 and not acknowledge_pending");
193
+ expect(t.actions).toHaveLength(7);
194
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
195
+ expect(t.actions[0].kind).toBe("subroutine");
196
+ expect(t.actions[1].verb).toBe("V(r) := V(r) + 1");
197
+ expect(t.actions[1].kind).toBe("processing");
198
+ expect(t.actions[2].verb).toBe("clear_reject_exception");
199
+ expect(t.actions[2].kind).toBe("processing");
200
+ expect(t.actions[3].verb).toBe("decrement_srej_exception_if_gt_0");
201
+ expect(t.actions[3].kind).toBe("processing");
202
+ expect(t.actions[4].verb).toBe("DL_DATA_indication");
203
+ expect(t.actions[4].kind).toBe("signal_upper");
204
+ expect(t.actions[5].verb).toBe("LM_seize_request");
205
+ expect(t.actions[5].kind).toBe("signal_lower");
206
+ expect(t.actions[6].verb).toBe("set_acknowledge_pending");
207
+ expect(t.actions[6].kind).toBe("processing");
208
+ });
209
+ it("t12_i_received_out_of_seq_reject_exception_p_eq_1", () => {
210
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t12_i_received_out_of_seq_reject_exception_p_eq_1");
211
+ expect(t, "transition t12_i_received_out_of_seq_reject_exception_p_eq_1 not found").toBeDefined();
212
+ if (!t)
213
+ return;
214
+ expect(t.on).toBe("I_received");
215
+ expect(t.next).toBe("Connected");
216
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and not N_s_eq_V_r and reject_exception and P_eq_1");
217
+ expect(t.actions).toHaveLength(6);
218
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
219
+ expect(t.actions[0].kind).toBe("subroutine");
220
+ expect(t.actions[1].verb).toBe("discard_contents_of_I_frame");
221
+ expect(t.actions[1].kind).toBe("processing");
222
+ expect(t.actions[2].verb).toBe("F := 1");
223
+ expect(t.actions[2].kind).toBe("processing");
224
+ expect(t.actions[3].verb).toBe("N(r) := V(r)");
225
+ expect(t.actions[3].kind).toBe("processing");
226
+ expect(t.actions[4].verb).toBe("RR");
227
+ expect(t.actions[4].kind).toBe("signal_lower");
228
+ expect(t.actions[5].verb).toBe("clear_acknowledge_pending");
229
+ expect(t.actions[5].kind).toBe("processing");
230
+ });
231
+ it("t13_i_received_out_of_seq_reject_exception_p_eq_0", () => {
232
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t13_i_received_out_of_seq_reject_exception_p_eq_0");
233
+ expect(t, "transition t13_i_received_out_of_seq_reject_exception_p_eq_0 not found").toBeDefined();
234
+ if (!t)
235
+ return;
236
+ expect(t.on).toBe("I_received");
237
+ expect(t.next).toBe("Connected");
238
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and not N_s_eq_V_r and reject_exception and not P_eq_1");
239
+ expect(t.actions).toHaveLength(2);
240
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
241
+ expect(t.actions[0].kind).toBe("subroutine");
242
+ expect(t.actions[1].verb).toBe("discard_contents_of_I_frame");
243
+ expect(t.actions[1].kind).toBe("processing");
244
+ });
245
+ it("t14_i_received_out_of_seq_srej_enabled_no_excep_in_range", () => {
246
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t14_i_received_out_of_seq_srej_enabled_no_excep_in_range");
247
+ expect(t, "transition t14_i_received_out_of_seq_srej_enabled_no_excep_in_range not found").toBeDefined();
248
+ if (!t)
249
+ return;
250
+ expect(t.on).toBe("I_received");
251
+ expect(t.next).toBe("Connected");
252
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and not N_s_eq_V_r and not reject_exception and srej_enabled and not srej_exception_gt_0 and not N_s_gt_V_r_plus_1");
253
+ expect(t.actions).toHaveLength(6);
254
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
255
+ expect(t.actions[0].kind).toBe("subroutine");
256
+ expect(t.actions[1].verb).toBe("save_contents_of_I_frame");
257
+ expect(t.actions[1].kind).toBe("processing");
258
+ expect(t.actions[2].verb).toBe("N(r) := V(r)");
259
+ expect(t.actions[2].kind).toBe("processing");
260
+ expect(t.actions[3].verb).toBe("F := 1");
261
+ expect(t.actions[3].kind).toBe("processing");
262
+ expect(t.actions[4].verb).toBe("increment_srej_exception");
263
+ expect(t.actions[4].kind).toBe("processing");
264
+ expect(t.actions[5].verb).toBe("SREJ");
265
+ expect(t.actions[5].kind).toBe("signal_lower");
266
+ });
267
+ it("t15_i_received_out_of_seq_srej_enabled_no_excep_far_skip", () => {
268
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t15_i_received_out_of_seq_srej_enabled_no_excep_far_skip");
269
+ expect(t, "transition t15_i_received_out_of_seq_srej_enabled_no_excep_far_skip not found").toBeDefined();
270
+ if (!t)
271
+ return;
272
+ expect(t.on).toBe("I_received");
273
+ expect(t.next).toBe("Connected");
274
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and not N_s_eq_V_r and not reject_exception and srej_enabled and not srej_exception_gt_0 and N_s_gt_V_r_plus_1");
275
+ expect(t.actions).toHaveLength(8);
276
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
277
+ expect(t.actions[0].kind).toBe("subroutine");
278
+ expect(t.actions[1].verb).toBe("save_contents_of_I_frame");
279
+ expect(t.actions[1].kind).toBe("processing");
280
+ expect(t.actions[2].verb).toBe("discard_contents_of_I_frame");
281
+ expect(t.actions[2].kind).toBe("processing");
282
+ expect(t.actions[3].verb).toBe("set_reject_exception");
283
+ expect(t.actions[3].kind).toBe("processing");
284
+ expect(t.actions[4].verb).toBe("F := P");
285
+ expect(t.actions[4].kind).toBe("processing");
286
+ expect(t.actions[5].verb).toBe("N(r) := V(r)");
287
+ expect(t.actions[5].kind).toBe("processing");
288
+ expect(t.actions[6].verb).toBe("REJ");
289
+ expect(t.actions[6].kind).toBe("signal_lower");
290
+ expect(t.actions[7].verb).toBe("clear_acknowledge_pending");
291
+ expect(t.actions[7].kind).toBe("processing");
292
+ });
293
+ it("t16_i_received_out_of_seq_srej_enabled_existing_excep", () => {
294
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t16_i_received_out_of_seq_srej_enabled_existing_excep");
295
+ expect(t, "transition t16_i_received_out_of_seq_srej_enabled_existing_excep not found").toBeDefined();
296
+ if (!t)
297
+ return;
298
+ expect(t.on).toBe("I_received");
299
+ expect(t.next).toBe("Connected");
300
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and not N_s_eq_V_r and not reject_exception and srej_enabled and srej_exception_gt_0");
301
+ expect(t.actions).toHaveLength(6);
302
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
303
+ expect(t.actions[0].kind).toBe("subroutine");
304
+ expect(t.actions[1].verb).toBe("save_contents_of_I_frame");
305
+ expect(t.actions[1].kind).toBe("processing");
306
+ expect(t.actions[2].verb).toBe("N(r) := N(s)");
307
+ expect(t.actions[2].kind).toBe("processing");
308
+ expect(t.actions[3].verb).toBe("F := 0");
309
+ expect(t.actions[3].kind).toBe("processing");
310
+ expect(t.actions[4].verb).toBe("increment_srej_exception");
311
+ expect(t.actions[4].kind).toBe("processing");
312
+ expect(t.actions[5].verb).toBe("SREJ");
313
+ expect(t.actions[5].kind).toBe("signal_lower");
314
+ });
315
+ it("t17_i_received_out_of_seq_srej_disabled", () => {
316
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t17_i_received_out_of_seq_srej_disabled");
317
+ expect(t, "transition t17_i_received_out_of_seq_srej_disabled not found").toBeDefined();
318
+ if (!t)
319
+ return;
320
+ expect(t.on).toBe("I_received");
321
+ expect(t.next).toBe("Connected");
322
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and not N_s_eq_V_r and not reject_exception and not srej_enabled");
323
+ expect(t.actions).toHaveLength(7);
324
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
325
+ expect(t.actions[0].kind).toBe("subroutine");
326
+ expect(t.actions[1].verb).toBe("discard_contents_of_I_frame");
327
+ expect(t.actions[1].kind).toBe("processing");
328
+ expect(t.actions[2].verb).toBe("set_reject_exception");
329
+ expect(t.actions[2].kind).toBe("processing");
330
+ expect(t.actions[3].verb).toBe("F := P");
331
+ expect(t.actions[3].kind).toBe("processing");
332
+ expect(t.actions[4].verb).toBe("N(r) := V(r)");
333
+ expect(t.actions[4].kind).toBe("processing");
334
+ expect(t.actions[5].verb).toBe("REJ");
335
+ expect(t.actions[5].kind).toBe("signal_lower");
336
+ expect(t.actions[6].verb).toBe("clear_acknowledge_pending");
337
+ expect(t.actions[6].kind).toBe("processing");
338
+ });
339
+ it("t18_dl_data_request", () => {
340
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t18_dl_data_request");
341
+ expect(t, "transition t18_dl_data_request not found").toBeDefined();
342
+ if (!t)
343
+ return;
344
+ expect(t.on).toBe("DL_DATA_request");
345
+ expect(t.next).toBe("Connected");
346
+ expect(t.actions).toHaveLength(1);
347
+ expect(t.actions[0].verb).toBe("push_on_I_frame_queue");
348
+ expect(t.actions[0].kind).toBe("internal_out");
349
+ });
350
+ it("t19_i_frame_pops_off_queue_send_now_t1_running", () => {
351
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t19_i_frame_pops_off_queue_send_now_t1_running");
352
+ expect(t, "transition t19_i_frame_pops_off_queue_send_now_t1_running not found").toBeDefined();
353
+ if (!t)
354
+ return;
355
+ expect(t.on).toBe("I_frame_pops_off_queue");
356
+ expect(t.next).toBe("Connected");
357
+ expect(t.guard).toBe("not peer_receiver_busy and not V_s_eq_V_a_plus_k and T1_running");
358
+ expect(t.actions).toHaveLength(6);
359
+ expect(t.actions[0].verb).toBe("N(s) := V(s)");
360
+ expect(t.actions[0].kind).toBe("processing");
361
+ expect(t.actions[1].verb).toBe("N(r) := V(r)");
362
+ expect(t.actions[1].kind).toBe("processing");
363
+ expect(t.actions[2].verb).toBe("p := 0");
364
+ expect(t.actions[2].kind).toBe("processing");
365
+ expect(t.actions[3].verb).toBe("I_command");
366
+ expect(t.actions[3].kind).toBe("signal_lower");
367
+ expect(t.actions[4].verb).toBe("V(s) := V(s) + 1");
368
+ expect(t.actions[4].kind).toBe("processing");
369
+ expect(t.actions[5].verb).toBe("clear_acknowledge_pending");
370
+ expect(t.actions[5].kind).toBe("processing");
371
+ });
372
+ it("t20_i_frame_pops_off_queue_send_now_t1_not_running", () => {
373
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t20_i_frame_pops_off_queue_send_now_t1_not_running");
374
+ expect(t, "transition t20_i_frame_pops_off_queue_send_now_t1_not_running not found").toBeDefined();
375
+ if (!t)
376
+ return;
377
+ expect(t.on).toBe("I_frame_pops_off_queue");
378
+ expect(t.next).toBe("Connected");
379
+ expect(t.guard).toBe("not peer_receiver_busy and not V_s_eq_V_a_plus_k and not T1_running");
380
+ expect(t.actions).toHaveLength(8);
381
+ expect(t.actions[0].verb).toBe("N(s) := V(s)");
382
+ expect(t.actions[0].kind).toBe("processing");
383
+ expect(t.actions[1].verb).toBe("N(r) := V(r)");
384
+ expect(t.actions[1].kind).toBe("processing");
385
+ expect(t.actions[2].verb).toBe("p := 0");
386
+ expect(t.actions[2].kind).toBe("processing");
387
+ expect(t.actions[3].verb).toBe("I_command");
388
+ expect(t.actions[3].kind).toBe("signal_lower");
389
+ expect(t.actions[4].verb).toBe("V(s) := V(s) + 1");
390
+ expect(t.actions[4].kind).toBe("processing");
391
+ expect(t.actions[5].verb).toBe("clear_acknowledge_pending");
392
+ expect(t.actions[5].kind).toBe("processing");
393
+ expect(t.actions[6].verb).toBe("stop_T3");
394
+ expect(t.actions[6].kind).toBe("processing");
395
+ expect(t.actions[7].verb).toBe("start_T1");
396
+ expect(t.actions[7].kind).toBe("processing");
397
+ });
398
+ it("t21_i_frame_pops_off_queue_window_full", () => {
399
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t21_i_frame_pops_off_queue_window_full");
400
+ expect(t, "transition t21_i_frame_pops_off_queue_window_full not found").toBeDefined();
401
+ if (!t)
402
+ return;
403
+ expect(t.on).toBe("I_frame_pops_off_queue");
404
+ expect(t.next).toBe("Connected");
405
+ expect(t.guard).toBe("not peer_receiver_busy and V_s_eq_V_a_plus_k");
406
+ expect(t.actions).toHaveLength(1);
407
+ expect(t.actions[0].verb).toBe("push_on_I_frame_queue");
408
+ expect(t.actions[0].kind).toBe("internal_out");
409
+ });
410
+ it("t22_i_frame_pops_off_queue_peer_busy", () => {
411
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t22_i_frame_pops_off_queue_peer_busy");
412
+ expect(t, "transition t22_i_frame_pops_off_queue_peer_busy not found").toBeDefined();
413
+ if (!t)
414
+ return;
415
+ expect(t.on).toBe("I_frame_pops_off_queue");
416
+ expect(t.next).toBe("Connected");
417
+ expect(t.guard).toBe("peer_receiver_busy");
418
+ expect(t.actions).toHaveLength(1);
419
+ expect(t.actions[0].verb).toBe("push_on_I_frame_queue");
420
+ expect(t.actions[0].kind).toBe("internal_out");
421
+ });
422
+ it("t23_dl_unit_data_request", () => {
423
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t23_dl_unit_data_request");
424
+ expect(t, "transition t23_dl_unit_data_request not found").toBeDefined();
425
+ if (!t)
426
+ return;
427
+ expect(t.on).toBe("DL_UNIT_DATA_request");
428
+ expect(t.next).toBe("Connected");
429
+ expect(t.actions).toHaveLength(1);
430
+ expect(t.actions[0].verb).toBe("UI_command");
431
+ expect(t.actions[0].kind).toBe("signal_lower");
432
+ });
433
+ it("t24_dl_flow_off_when_not_busy", () => {
434
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t24_dl_flow_off_when_not_busy");
435
+ expect(t, "transition t24_dl_flow_off_when_not_busy not found").toBeDefined();
436
+ if (!t)
437
+ return;
438
+ expect(t.on).toBe("DL_FLOW_OFF_request");
439
+ expect(t.next).toBe("Connected");
440
+ expect(t.guard).toBe("own_receiver_busy");
441
+ expect(t.actions).toHaveLength(3);
442
+ expect(t.actions[0].verb).toBe("set_own_receiver_busy");
443
+ expect(t.actions[0].kind).toBe("processing");
444
+ expect(t.actions[1].verb).toBe("RNR_response");
445
+ expect(t.actions[1].kind).toBe("signal_lower");
446
+ expect(t.actions[2].verb).toBe("clear_acknowledge_pending");
447
+ expect(t.actions[2].kind).toBe("processing");
448
+ });
449
+ it("t25_dl_flow_off_when_already_busy", () => {
450
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t25_dl_flow_off_when_already_busy");
451
+ expect(t, "transition t25_dl_flow_off_when_already_busy not found").toBeDefined();
452
+ if (!t)
453
+ return;
454
+ expect(t.on).toBe("DL_FLOW_OFF_request");
455
+ expect(t.next).toBe("Connected");
456
+ expect(t.guard).toBe("not own_receiver_busy");
457
+ expect(t.actions).toHaveLength(0);
458
+ });
459
+ it("t26_dl_flow_on_when_busy_and_t1_not_running", () => {
460
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t26_dl_flow_on_when_busy_and_t1_not_running");
461
+ expect(t, "transition t26_dl_flow_on_when_busy_and_t1_not_running not found").toBeDefined();
462
+ if (!t)
463
+ return;
464
+ expect(t.on).toBe("DL_FLOW_ON_request");
465
+ expect(t.next).toBe("Connected");
466
+ expect(t.guard).toBe("own_receiver_busy and not T1_running");
467
+ expect(t.actions).toHaveLength(5);
468
+ expect(t.actions[0].verb).toBe("clear_own_receiver_busy");
469
+ expect(t.actions[0].kind).toBe("processing");
470
+ expect(t.actions[1].verb).toBe("RR_command");
471
+ expect(t.actions[1].kind).toBe("signal_lower");
472
+ expect(t.actions[2].verb).toBe("clear_acknowledge_pending");
473
+ expect(t.actions[2].kind).toBe("processing");
474
+ expect(t.actions[3].verb).toBe("stop_T3");
475
+ expect(t.actions[3].kind).toBe("processing");
476
+ expect(t.actions[4].verb).toBe("start_T1");
477
+ expect(t.actions[4].kind).toBe("processing");
478
+ });
479
+ it("t27_dl_flow_on_when_busy_and_t1_running", () => {
480
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t27_dl_flow_on_when_busy_and_t1_running");
481
+ expect(t, "transition t27_dl_flow_on_when_busy_and_t1_running not found").toBeDefined();
482
+ if (!t)
483
+ return;
484
+ expect(t.on).toBe("DL_FLOW_ON_request");
485
+ expect(t.next).toBe("Connected");
486
+ expect(t.guard).toBe("own_receiver_busy and T1_running");
487
+ expect(t.actions).toHaveLength(3);
488
+ expect(t.actions[0].verb).toBe("clear_own_receiver_busy");
489
+ expect(t.actions[0].kind).toBe("processing");
490
+ expect(t.actions[1].verb).toBe("RR_command");
491
+ expect(t.actions[1].kind).toBe("signal_lower");
492
+ expect(t.actions[2].verb).toBe("clear_acknowledge_pending");
493
+ expect(t.actions[2].kind).toBe("processing");
494
+ });
495
+ it("t28_dl_flow_on_when_not_busy", () => {
496
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t28_dl_flow_on_when_not_busy");
497
+ expect(t, "transition t28_dl_flow_on_when_not_busy not found").toBeDefined();
498
+ if (!t)
499
+ return;
500
+ expect(t.on).toBe("DL_FLOW_ON_request");
501
+ expect(t.next).toBe("Connected");
502
+ expect(t.guard).toBe("not own_receiver_busy");
503
+ expect(t.actions).toHaveLength(0);
504
+ });
505
+ it("t29_dl_connect_request_v22", () => {
506
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t29_dl_connect_request_v22");
507
+ expect(t, "transition t29_dl_connect_request_v22 not found").toBeDefined();
508
+ if (!t)
509
+ return;
510
+ expect(t.on).toBe("DL_CONNECT_request");
511
+ expect(t.next).toBe("AwaitingConnection22");
512
+ expect(t.guard).toBe("version_2_2");
513
+ expect(t.actions).toHaveLength(3);
514
+ expect(t.actions[0].verb).toBe("discard_I_frame_queue");
515
+ expect(t.actions[0].kind).toBe("processing");
516
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
517
+ expect(t.actions[1].kind).toBe("subroutine");
518
+ expect(t.actions[2].verb).toBe("set_layer_3_initiated");
519
+ expect(t.actions[2].kind).toBe("processing");
520
+ });
521
+ it("t30_dl_connect_request_v20", () => {
522
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t30_dl_connect_request_v20");
523
+ expect(t, "transition t30_dl_connect_request_v20 not found").toBeDefined();
524
+ if (!t)
525
+ return;
526
+ expect(t.on).toBe("DL_CONNECT_request");
527
+ expect(t.next).toBe("AwaitingConnection");
528
+ expect(t.guard).toBe("not version_2_2");
529
+ expect(t.actions).toHaveLength(3);
530
+ expect(t.actions[0].verb).toBe("discard_I_frame_queue");
531
+ expect(t.actions[0].kind).toBe("processing");
532
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
533
+ expect(t.actions[1].kind).toBe("subroutine");
534
+ expect(t.actions[2].verb).toBe("set_layer_3_initiated");
535
+ expect(t.actions[2].kind).toBe("processing");
536
+ });
537
+ it("t31_all_other_primitives_from_lower_layer", () => {
538
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t31_all_other_primitives_from_lower_layer");
539
+ expect(t, "transition t31_all_other_primitives_from_lower_layer not found").toBeDefined();
540
+ if (!t)
541
+ return;
542
+ expect(t.on).toBe("all_other_primitives__from_lower_layer");
543
+ expect(t.next).toBe("Connected");
544
+ expect(t.actions).toHaveLength(0);
545
+ });
546
+ it("t32_control_field_error_v22", () => {
547
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t32_control_field_error_v22");
548
+ expect(t, "transition t32_control_field_error_v22 not found").toBeDefined();
549
+ if (!t)
550
+ return;
551
+ expect(t.on).toBe("control_field_error");
552
+ expect(t.next).toBe("AwaitingConnection22");
553
+ expect(t.guard).toBe("version_2_2");
554
+ expect(t.actions).toHaveLength(4);
555
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_L");
556
+ expect(t.actions[0].kind).toBe("signal_upper");
557
+ expect(t.actions[1].verb).toBe("discard_I_frame_queue");
558
+ expect(t.actions[1].kind).toBe("processing");
559
+ expect(t.actions[2].verb).toBe("Establish_Data_Link");
560
+ expect(t.actions[2].kind).toBe("subroutine");
561
+ expect(t.actions[3].verb).toBe("set_layer_3_initiated");
562
+ expect(t.actions[3].kind).toBe("processing");
563
+ });
564
+ it("t33_control_field_error_v20", () => {
565
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t33_control_field_error_v20");
566
+ expect(t, "transition t33_control_field_error_v20 not found").toBeDefined();
567
+ if (!t)
568
+ return;
569
+ expect(t.on).toBe("control_field_error");
570
+ expect(t.next).toBe("AwaitingConnection");
571
+ expect(t.guard).toBe("not version_2_2");
572
+ expect(t.actions).toHaveLength(4);
573
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_L");
574
+ expect(t.actions[0].kind).toBe("signal_upper");
575
+ expect(t.actions[1].verb).toBe("discard_I_frame_queue");
576
+ expect(t.actions[1].kind).toBe("processing");
577
+ expect(t.actions[2].verb).toBe("Establish_Data_Link");
578
+ expect(t.actions[2].kind).toBe("subroutine");
579
+ expect(t.actions[3].verb).toBe("set_layer_3_initiated");
580
+ expect(t.actions[3].kind).toBe("processing");
581
+ });
582
+ it("t34_info_not_permitted_in_frame_v22", () => {
583
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t34_info_not_permitted_in_frame_v22");
584
+ expect(t, "transition t34_info_not_permitted_in_frame_v22 not found").toBeDefined();
585
+ if (!t)
586
+ return;
587
+ expect(t.on).toBe("info_not_permitted_in_frame");
588
+ expect(t.next).toBe("AwaitingConnection22");
589
+ expect(t.guard).toBe("version_2_2");
590
+ expect(t.actions).toHaveLength(4);
591
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_M");
592
+ expect(t.actions[0].kind).toBe("signal_upper");
593
+ expect(t.actions[1].verb).toBe("discard_I_frame_queue");
594
+ expect(t.actions[1].kind).toBe("processing");
595
+ expect(t.actions[2].verb).toBe("Establish_Data_Link");
596
+ expect(t.actions[2].kind).toBe("subroutine");
597
+ expect(t.actions[3].verb).toBe("set_layer_3_initiated");
598
+ expect(t.actions[3].kind).toBe("processing");
599
+ });
600
+ it("t35_info_not_permitted_in_frame_v20", () => {
601
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t35_info_not_permitted_in_frame_v20");
602
+ expect(t, "transition t35_info_not_permitted_in_frame_v20 not found").toBeDefined();
603
+ if (!t)
604
+ return;
605
+ expect(t.on).toBe("info_not_permitted_in_frame");
606
+ expect(t.next).toBe("AwaitingConnection");
607
+ expect(t.guard).toBe("not version_2_2");
608
+ expect(t.actions).toHaveLength(4);
609
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_M");
610
+ expect(t.actions[0].kind).toBe("signal_upper");
611
+ expect(t.actions[1].verb).toBe("discard_I_frame_queue");
612
+ expect(t.actions[1].kind).toBe("processing");
613
+ expect(t.actions[2].verb).toBe("Establish_Data_Link");
614
+ expect(t.actions[2].kind).toBe("subroutine");
615
+ expect(t.actions[3].verb).toBe("set_layer_3_initiated");
616
+ expect(t.actions[3].kind).toBe("processing");
617
+ });
618
+ it("t36_u_or_s_frame_length_error_v22", () => {
619
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t36_u_or_s_frame_length_error_v22");
620
+ expect(t, "transition t36_u_or_s_frame_length_error_v22 not found").toBeDefined();
621
+ if (!t)
622
+ return;
623
+ expect(t.on).toBe("u_or_s_frame_length_error");
624
+ expect(t.next).toBe("AwaitingConnection22");
625
+ expect(t.guard).toBe("version_2_2");
626
+ expect(t.actions).toHaveLength(4);
627
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_N");
628
+ expect(t.actions[0].kind).toBe("signal_upper");
629
+ expect(t.actions[1].verb).toBe("discard_I_frame_queue");
630
+ expect(t.actions[1].kind).toBe("processing");
631
+ expect(t.actions[2].verb).toBe("Establish_Data_Link");
632
+ expect(t.actions[2].kind).toBe("subroutine");
633
+ expect(t.actions[3].verb).toBe("set_layer_3_initiated");
634
+ expect(t.actions[3].kind).toBe("processing");
635
+ });
636
+ it("t37_u_or_s_frame_length_error_v20", () => {
637
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t37_u_or_s_frame_length_error_v20");
638
+ expect(t, "transition t37_u_or_s_frame_length_error_v20 not found").toBeDefined();
639
+ if (!t)
640
+ return;
641
+ expect(t.on).toBe("u_or_s_frame_length_error");
642
+ expect(t.next).toBe("AwaitingConnection");
643
+ expect(t.guard).toBe("not version_2_2");
644
+ expect(t.actions).toHaveLength(4);
645
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_N");
646
+ expect(t.actions[0].kind).toBe("signal_upper");
647
+ expect(t.actions[1].verb).toBe("discard_I_frame_queue");
648
+ expect(t.actions[1].kind).toBe("processing");
649
+ expect(t.actions[2].verb).toBe("Establish_Data_Link");
650
+ expect(t.actions[2].kind).toBe("subroutine");
651
+ expect(t.actions[3].verb).toBe("set_layer_3_initiated");
652
+ expect(t.actions[3].kind).toBe("processing");
653
+ });
654
+ it("t38_t1_expiry", () => {
655
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t38_t1_expiry");
656
+ expect(t, "transition t38_t1_expiry not found").toBeDefined();
657
+ if (!t)
658
+ return;
659
+ expect(t.on).toBe("T1_expiry");
660
+ expect(t.next).toBe("TimerRecovery");
661
+ expect(t.actions).toHaveLength(2);
662
+ expect(t.actions[0].verb).toBe("RC := 1");
663
+ expect(t.actions[0].kind).toBe("processing");
664
+ expect(t.actions[1].verb).toBe("Transmit_Enquiry");
665
+ expect(t.actions[1].kind).toBe("subroutine");
666
+ });
667
+ it("t39_t3_expiry", () => {
668
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t39_t3_expiry");
669
+ expect(t, "transition t39_t3_expiry not found").toBeDefined();
670
+ if (!t)
671
+ return;
672
+ expect(t.on).toBe("T3_expiry");
673
+ expect(t.next).toBe("TimerRecovery");
674
+ expect(t.actions).toHaveLength(2);
675
+ expect(t.actions[0].verb).toBe("RC := 1");
676
+ expect(t.actions[0].kind).toBe("processing");
677
+ expect(t.actions[1].verb).toBe("Transmit_Enquiry");
678
+ expect(t.actions[1].kind).toBe("subroutine");
679
+ });
680
+ it("t40_sabm_received_vs_neq_va", () => {
681
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t40_sabm_received_vs_neq_va");
682
+ expect(t, "transition t40_sabm_received_vs_neq_va not found").toBeDefined();
683
+ if (!t)
684
+ return;
685
+ expect(t.on).toBe("SABM_received");
686
+ expect(t.next).toBe("Connected");
687
+ expect(t.guard).toBe("not V_s_eq_V_a");
688
+ expect(t.actions).toHaveLength(13);
689
+ expect(t.actions[0].verb).toBe("F := P");
690
+ expect(t.actions[0].kind).toBe("processing");
691
+ expect(t.actions[1].verb).toBe("set_version_2_0");
692
+ expect(t.actions[1].kind).toBe("processing");
693
+ expect(t.actions[2].verb).toBe("UA");
694
+ expect(t.actions[2].kind).toBe("signal_lower");
695
+ expect(t.actions[3].verb).toBe("Clear_Exception_Conditions");
696
+ expect(t.actions[3].kind).toBe("subroutine");
697
+ expect(t.actions[4].verb).toBe("DL_ERROR_indication_F");
698
+ expect(t.actions[4].kind).toBe("signal_upper");
699
+ expect(t.actions[5].verb).toBe("discard_I_frame_queue");
700
+ expect(t.actions[5].kind).toBe("processing");
701
+ expect(t.actions[6].verb).toBe("DL_CONNECT_indication");
702
+ expect(t.actions[6].kind).toBe("signal_upper");
703
+ expect(t.actions[7].verb).toBe("stop_T1");
704
+ expect(t.actions[7].kind).toBe("processing");
705
+ expect(t.actions[8].verb).toBe("start_T3");
706
+ expect(t.actions[8].kind).toBe("processing");
707
+ expect(t.actions[9].verb).toBe("V(a) := 0");
708
+ expect(t.actions[9].kind).toBe("processing");
709
+ expect(t.actions[10].verb).toBe("V(s) := 0");
710
+ expect(t.actions[10].kind).toBe("processing");
711
+ expect(t.actions[11].verb).toBe("V(r) := 0");
712
+ expect(t.actions[11].kind).toBe("processing");
713
+ expect(t.actions[12].verb).toBe("RC := 0");
714
+ expect(t.actions[12].kind).toBe("processing");
715
+ });
716
+ it("t41_sabm_received_vs_eq_va", () => {
717
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t41_sabm_received_vs_eq_va");
718
+ expect(t, "transition t41_sabm_received_vs_eq_va not found").toBeDefined();
719
+ if (!t)
720
+ return;
721
+ expect(t.on).toBe("SABM_received");
722
+ expect(t.next).toBe("Connected");
723
+ expect(t.guard).toBe("V_s_eq_V_a");
724
+ expect(t.actions).toHaveLength(11);
725
+ expect(t.actions[0].verb).toBe("F := P");
726
+ expect(t.actions[0].kind).toBe("processing");
727
+ expect(t.actions[1].verb).toBe("set_version_2_0");
728
+ expect(t.actions[1].kind).toBe("processing");
729
+ expect(t.actions[2].verb).toBe("UA");
730
+ expect(t.actions[2].kind).toBe("signal_lower");
731
+ expect(t.actions[3].verb).toBe("Clear_Exception_Conditions");
732
+ expect(t.actions[3].kind).toBe("subroutine");
733
+ expect(t.actions[4].verb).toBe("DL_ERROR_indication_F");
734
+ expect(t.actions[4].kind).toBe("signal_upper");
735
+ expect(t.actions[5].verb).toBe("stop_T1");
736
+ expect(t.actions[5].kind).toBe("processing");
737
+ expect(t.actions[6].verb).toBe("start_T3");
738
+ expect(t.actions[6].kind).toBe("processing");
739
+ expect(t.actions[7].verb).toBe("V(a) := 0");
740
+ expect(t.actions[7].kind).toBe("processing");
741
+ expect(t.actions[8].verb).toBe("V(s) := 0");
742
+ expect(t.actions[8].kind).toBe("processing");
743
+ expect(t.actions[9].verb).toBe("V(r) := 0");
744
+ expect(t.actions[9].kind).toBe("processing");
745
+ expect(t.actions[10].verb).toBe("RC := 0");
746
+ expect(t.actions[10].kind).toBe("processing");
747
+ });
748
+ it("t42_sabme_received_vs_neq_va", () => {
749
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t42_sabme_received_vs_neq_va");
750
+ expect(t, "transition t42_sabme_received_vs_neq_va not found").toBeDefined();
751
+ if (!t)
752
+ return;
753
+ expect(t.on).toBe("SABME_received");
754
+ expect(t.next).toBe("Connected");
755
+ expect(t.guard).toBe("not V_s_eq_V_a");
756
+ expect(t.actions).toHaveLength(13);
757
+ expect(t.actions[0].verb).toBe("F := P");
758
+ expect(t.actions[0].kind).toBe("processing");
759
+ expect(t.actions[1].verb).toBe("set_version_2_2");
760
+ expect(t.actions[1].kind).toBe("processing");
761
+ expect(t.actions[2].verb).toBe("UA");
762
+ expect(t.actions[2].kind).toBe("signal_lower");
763
+ expect(t.actions[3].verb).toBe("Clear_Exception_Conditions");
764
+ expect(t.actions[3].kind).toBe("subroutine");
765
+ expect(t.actions[4].verb).toBe("DL_ERROR_indication_F");
766
+ expect(t.actions[4].kind).toBe("signal_upper");
767
+ expect(t.actions[5].verb).toBe("discard_I_frame_queue");
768
+ expect(t.actions[5].kind).toBe("processing");
769
+ expect(t.actions[6].verb).toBe("DL_CONNECT_indication");
770
+ expect(t.actions[6].kind).toBe("signal_upper");
771
+ expect(t.actions[7].verb).toBe("stop_T1");
772
+ expect(t.actions[7].kind).toBe("processing");
773
+ expect(t.actions[8].verb).toBe("start_T3");
774
+ expect(t.actions[8].kind).toBe("processing");
775
+ expect(t.actions[9].verb).toBe("V(a) := 0");
776
+ expect(t.actions[9].kind).toBe("processing");
777
+ expect(t.actions[10].verb).toBe("V(s) := 0");
778
+ expect(t.actions[10].kind).toBe("processing");
779
+ expect(t.actions[11].verb).toBe("V(r) := 0");
780
+ expect(t.actions[11].kind).toBe("processing");
781
+ expect(t.actions[12].verb).toBe("RC := 0");
782
+ expect(t.actions[12].kind).toBe("processing");
783
+ });
784
+ it("t43_sabme_received_vs_eq_va", () => {
785
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t43_sabme_received_vs_eq_va");
786
+ expect(t, "transition t43_sabme_received_vs_eq_va not found").toBeDefined();
787
+ if (!t)
788
+ return;
789
+ expect(t.on).toBe("SABME_received");
790
+ expect(t.next).toBe("Connected");
791
+ expect(t.guard).toBe("V_s_eq_V_a");
792
+ expect(t.actions).toHaveLength(11);
793
+ expect(t.actions[0].verb).toBe("F := P");
794
+ expect(t.actions[0].kind).toBe("processing");
795
+ expect(t.actions[1].verb).toBe("set_version_2_2");
796
+ expect(t.actions[1].kind).toBe("processing");
797
+ expect(t.actions[2].verb).toBe("UA");
798
+ expect(t.actions[2].kind).toBe("signal_lower");
799
+ expect(t.actions[3].verb).toBe("Clear_Exception_Conditions");
800
+ expect(t.actions[3].kind).toBe("subroutine");
801
+ expect(t.actions[4].verb).toBe("DL_ERROR_indication_F");
802
+ expect(t.actions[4].kind).toBe("signal_upper");
803
+ expect(t.actions[5].verb).toBe("stop_T1");
804
+ expect(t.actions[5].kind).toBe("processing");
805
+ expect(t.actions[6].verb).toBe("start_T3");
806
+ expect(t.actions[6].kind).toBe("processing");
807
+ expect(t.actions[7].verb).toBe("V(a) := 0");
808
+ expect(t.actions[7].kind).toBe("processing");
809
+ expect(t.actions[8].verb).toBe("V(s) := 0");
810
+ expect(t.actions[8].kind).toBe("processing");
811
+ expect(t.actions[9].verb).toBe("V(r) := 0");
812
+ expect(t.actions[9].kind).toBe("processing");
813
+ expect(t.actions[10].verb).toBe("RC := 0");
814
+ expect(t.actions[10].kind).toBe("processing");
815
+ });
816
+ it("t44_frmr_received_v22", () => {
817
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t44_frmr_received_v22");
818
+ expect(t, "transition t44_frmr_received_v22 not found").toBeDefined();
819
+ if (!t)
820
+ return;
821
+ expect(t.on).toBe("FRMR_received");
822
+ expect(t.next).toBe("AwaitingConnection22");
823
+ expect(t.guard).toBe("version_2_2");
824
+ expect(t.actions).toHaveLength(3);
825
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_K");
826
+ expect(t.actions[0].kind).toBe("signal_upper");
827
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
828
+ expect(t.actions[1].kind).toBe("subroutine");
829
+ expect(t.actions[2].verb).toBe("clear_layer_3_initiated");
830
+ expect(t.actions[2].kind).toBe("processing");
831
+ });
832
+ it("t45_frmr_received_v20", () => {
833
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t45_frmr_received_v20");
834
+ expect(t, "transition t45_frmr_received_v20 not found").toBeDefined();
835
+ if (!t)
836
+ return;
837
+ expect(t.on).toBe("FRMR_received");
838
+ expect(t.next).toBe("AwaitingConnection");
839
+ expect(t.guard).toBe("not version_2_2");
840
+ expect(t.actions).toHaveLength(3);
841
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_K");
842
+ expect(t.actions[0].kind).toBe("signal_upper");
843
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
844
+ expect(t.actions[1].kind).toBe("subroutine");
845
+ expect(t.actions[2].verb).toBe("clear_layer_3_initiated");
846
+ expect(t.actions[2].kind).toBe("processing");
847
+ });
848
+ it("t46_ua_received_v22", () => {
849
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t46_ua_received_v22");
850
+ expect(t, "transition t46_ua_received_v22 not found").toBeDefined();
851
+ if (!t)
852
+ return;
853
+ expect(t.on).toBe("UA_received");
854
+ expect(t.next).toBe("AwaitingConnection22");
855
+ expect(t.guard).toBe("version_2_2");
856
+ expect(t.actions).toHaveLength(3);
857
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_K");
858
+ expect(t.actions[0].kind).toBe("signal_upper");
859
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
860
+ expect(t.actions[1].kind).toBe("subroutine");
861
+ expect(t.actions[2].verb).toBe("clear_layer_3_initiated");
862
+ expect(t.actions[2].kind).toBe("processing");
863
+ });
864
+ it("t47_ua_received_v20", () => {
865
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t47_ua_received_v20");
866
+ expect(t, "transition t47_ua_received_v20 not found").toBeDefined();
867
+ if (!t)
868
+ return;
869
+ expect(t.on).toBe("UA_received");
870
+ expect(t.next).toBe("AwaitingConnection");
871
+ expect(t.guard).toBe("not version_2_2");
872
+ expect(t.actions).toHaveLength(3);
873
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_K");
874
+ expect(t.actions[0].kind).toBe("signal_upper");
875
+ expect(t.actions[1].verb).toBe("Establish_Data_Link");
876
+ expect(t.actions[1].kind).toBe("subroutine");
877
+ expect(t.actions[2].verb).toBe("clear_layer_3_initiated");
878
+ expect(t.actions[2].kind).toBe("processing");
879
+ });
880
+ it("t48_ui_received_p_eq_0", () => {
881
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t48_ui_received_p_eq_0");
882
+ expect(t, "transition t48_ui_received_p_eq_0 not found").toBeDefined();
883
+ if (!t)
884
+ return;
885
+ expect(t.on).toBe("UI_received");
886
+ expect(t.next).toBe("Connected");
887
+ expect(t.guard).toBe("not P_eq_1");
888
+ expect(t.actions).toHaveLength(1);
889
+ expect(t.actions[0].verb).toBe("UI_Check");
890
+ expect(t.actions[0].kind).toBe("subroutine");
891
+ });
892
+ it("t49_ui_received_p_eq_1", () => {
893
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t49_ui_received_p_eq_1");
894
+ expect(t, "transition t49_ui_received_p_eq_1 not found").toBeDefined();
895
+ if (!t)
896
+ return;
897
+ expect(t.on).toBe("UI_received");
898
+ expect(t.next).toBe("Connected");
899
+ expect(t.guard).toBe("P_eq_1");
900
+ expect(t.actions).toHaveLength(2);
901
+ expect(t.actions[0].verb).toBe("UI_Check");
902
+ expect(t.actions[0].kind).toBe("subroutine");
903
+ expect(t.actions[1].verb).toBe("Enquiry_Response_F_1");
904
+ expect(t.actions[1].kind).toBe("subroutine");
905
+ });
906
+ it("t50_disc_received", () => {
907
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t50_disc_received");
908
+ expect(t, "transition t50_disc_received not found").toBeDefined();
909
+ if (!t)
910
+ return;
911
+ expect(t.on).toBe("DISC_received");
912
+ expect(t.next).toBe("Disconnected");
913
+ expect(t.actions).toHaveLength(6);
914
+ expect(t.actions[0].verb).toBe("discard_I_frame_queue");
915
+ expect(t.actions[0].kind).toBe("processing");
916
+ expect(t.actions[1].verb).toBe("F := P");
917
+ expect(t.actions[1].kind).toBe("processing");
918
+ expect(t.actions[2].verb).toBe("UA");
919
+ expect(t.actions[2].kind).toBe("signal_lower");
920
+ expect(t.actions[3].verb).toBe("DL_DISCONNECT_indication");
921
+ expect(t.actions[3].kind).toBe("signal_upper");
922
+ expect(t.actions[4].verb).toBe("stop_T3");
923
+ expect(t.actions[4].kind).toBe("processing");
924
+ expect(t.actions[5].verb).toBe("start_T1");
925
+ expect(t.actions[5].kind).toBe("processing");
926
+ });
927
+ it("t51_dm_received", () => {
928
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t51_dm_received");
929
+ expect(t, "transition t51_dm_received not found").toBeDefined();
930
+ if (!t)
931
+ return;
932
+ expect(t.on).toBe("DM_received");
933
+ expect(t.next).toBe("Disconnected");
934
+ expect(t.actions).toHaveLength(5);
935
+ expect(t.actions[0].verb).toBe("DL_ERROR_indication_E");
936
+ expect(t.actions[0].kind).toBe("signal_upper");
937
+ expect(t.actions[1].verb).toBe("DL_DISCONNECT_indication");
938
+ expect(t.actions[1].kind).toBe("signal_upper");
939
+ expect(t.actions[2].verb).toBe("discard_I_frame_queue");
940
+ expect(t.actions[2].kind).toBe("processing");
941
+ expect(t.actions[3].verb).toBe("stop_T1");
942
+ expect(t.actions[3].kind).toBe("processing");
943
+ expect(t.actions[4].verb).toBe("stop_T3");
944
+ expect(t.actions[4].kind).toBe("processing");
945
+ });
946
+ it("t52_rr_received_nr_in_window", () => {
947
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t52_rr_received_nr_in_window");
948
+ expect(t, "transition t52_rr_received_nr_in_window not found").toBeDefined();
949
+ if (!t)
950
+ return;
951
+ expect(t.on).toBe("RR_received");
952
+ expect(t.next).toBe("Connected");
953
+ expect(t.guard).toBe("V_a_le_N_r_le_V_s");
954
+ expect(t.actions).toHaveLength(3);
955
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
956
+ expect(t.actions[0].kind).toBe("processing");
957
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
958
+ expect(t.actions[1].kind).toBe("subroutine");
959
+ expect(t.actions[2].verb).toBe("Check_I_Frame_Acknowledged");
960
+ expect(t.actions[2].kind).toBe("subroutine");
961
+ });
962
+ it("t53_rr_received_nr_out_of_window_v22", () => {
963
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t53_rr_received_nr_out_of_window_v22");
964
+ expect(t, "transition t53_rr_received_nr_out_of_window_v22 not found").toBeDefined();
965
+ if (!t)
966
+ return;
967
+ expect(t.on).toBe("RR_received");
968
+ expect(t.next).toBe("AwaitingConnection22");
969
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and version_2_2");
970
+ expect(t.actions).toHaveLength(3);
971
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
972
+ expect(t.actions[0].kind).toBe("processing");
973
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
974
+ expect(t.actions[1].kind).toBe("subroutine");
975
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
976
+ expect(t.actions[2].kind).toBe("subroutine");
977
+ });
978
+ it("t54_rr_received_nr_out_of_window_v20", () => {
979
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t54_rr_received_nr_out_of_window_v20");
980
+ expect(t, "transition t54_rr_received_nr_out_of_window_v20 not found").toBeDefined();
981
+ if (!t)
982
+ return;
983
+ expect(t.on).toBe("RR_received");
984
+ expect(t.next).toBe("AwaitingConnection");
985
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and not version_2_2");
986
+ expect(t.actions).toHaveLength(3);
987
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
988
+ expect(t.actions[0].kind).toBe("processing");
989
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
990
+ expect(t.actions[1].kind).toBe("subroutine");
991
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
992
+ expect(t.actions[2].kind).toBe("subroutine");
993
+ });
994
+ it("t55_rnr_received_nr_in_window", () => {
995
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t55_rnr_received_nr_in_window");
996
+ expect(t, "transition t55_rnr_received_nr_in_window not found").toBeDefined();
997
+ if (!t)
998
+ return;
999
+ expect(t.on).toBe("RNR_received");
1000
+ expect(t.next).toBe("Connected");
1001
+ expect(t.guard).toBe("V_a_le_N_r_le_V_s");
1002
+ expect(t.actions).toHaveLength(3);
1003
+ expect(t.actions[0].verb).toBe("set_peer_receiver_busy");
1004
+ expect(t.actions[0].kind).toBe("processing");
1005
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1006
+ expect(t.actions[1].kind).toBe("subroutine");
1007
+ expect(t.actions[2].verb).toBe("Check_I_Frame_Acknowledged");
1008
+ expect(t.actions[2].kind).toBe("subroutine");
1009
+ });
1010
+ it("t56_rnr_received_nr_out_of_window_v22", () => {
1011
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t56_rnr_received_nr_out_of_window_v22");
1012
+ expect(t, "transition t56_rnr_received_nr_out_of_window_v22 not found").toBeDefined();
1013
+ if (!t)
1014
+ return;
1015
+ expect(t.on).toBe("RNR_received");
1016
+ expect(t.next).toBe("AwaitingConnection22");
1017
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and version_2_2");
1018
+ expect(t.actions).toHaveLength(3);
1019
+ expect(t.actions[0].verb).toBe("set_peer_receiver_busy");
1020
+ expect(t.actions[0].kind).toBe("processing");
1021
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1022
+ expect(t.actions[1].kind).toBe("subroutine");
1023
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
1024
+ expect(t.actions[2].kind).toBe("subroutine");
1025
+ });
1026
+ it("t57_rnr_received_nr_out_of_window_v20", () => {
1027
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t57_rnr_received_nr_out_of_window_v20");
1028
+ expect(t, "transition t57_rnr_received_nr_out_of_window_v20 not found").toBeDefined();
1029
+ if (!t)
1030
+ return;
1031
+ expect(t.on).toBe("RNR_received");
1032
+ expect(t.next).toBe("AwaitingConnection");
1033
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and not version_2_2");
1034
+ expect(t.actions).toHaveLength(3);
1035
+ expect(t.actions[0].verb).toBe("set_peer_receiver_busy");
1036
+ expect(t.actions[0].kind).toBe("processing");
1037
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1038
+ expect(t.actions[1].kind).toBe("subroutine");
1039
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
1040
+ expect(t.actions[2].kind).toBe("subroutine");
1041
+ });
1042
+ it("t58_lm_seize_confirm_no_ack_pending", () => {
1043
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t58_lm_seize_confirm_no_ack_pending");
1044
+ expect(t, "transition t58_lm_seize_confirm_no_ack_pending not found").toBeDefined();
1045
+ if (!t)
1046
+ return;
1047
+ expect(t.on).toBe("LM_SEIZE_confirm");
1048
+ expect(t.next).toBe("Connected");
1049
+ expect(t.guard).toBe("not acknowledge_pending");
1050
+ expect(t.actions).toHaveLength(1);
1051
+ expect(t.actions[0].verb).toBe("LM_release_request");
1052
+ expect(t.actions[0].kind).toBe("signal_lower");
1053
+ });
1054
+ it("t59_lm_seize_confirm_ack_pending", () => {
1055
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t59_lm_seize_confirm_ack_pending");
1056
+ expect(t, "transition t59_lm_seize_confirm_ack_pending not found").toBeDefined();
1057
+ if (!t)
1058
+ return;
1059
+ expect(t.on).toBe("LM_SEIZE_confirm");
1060
+ expect(t.next).toBe("Connected");
1061
+ expect(t.guard).toBe("acknowledge_pending");
1062
+ expect(t.actions).toHaveLength(3);
1063
+ expect(t.actions[0].verb).toBe("clear_acknowledge_pending");
1064
+ expect(t.actions[0].kind).toBe("processing");
1065
+ expect(t.actions[1].verb).toBe("Enquiry_Response_F_0");
1066
+ expect(t.actions[1].kind).toBe("subroutine");
1067
+ expect(t.actions[2].verb).toBe("LM_release_request");
1068
+ expect(t.actions[2].kind).toBe("signal_lower");
1069
+ });
1070
+ it("t60_srej_received_nr_in_window_pf_eq_0", () => {
1071
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t60_srej_received_nr_in_window_pf_eq_0");
1072
+ expect(t, "transition t60_srej_received_nr_in_window_pf_eq_0 not found").toBeDefined();
1073
+ if (!t)
1074
+ return;
1075
+ expect(t.on).toBe("SREJ_received");
1076
+ expect(t.next).toBe("Connected");
1077
+ expect(t.guard).toBe("V_a_le_N_r_le_V_s and not P_or_F_eq_1");
1078
+ expect(t.actions).toHaveLength(10);
1079
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1080
+ expect(t.actions[0].kind).toBe("processing");
1081
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1082
+ expect(t.actions[1].kind).toBe("subroutine");
1083
+ expect(t.actions[2].verb).toBe("stop_T1");
1084
+ expect(t.actions[2].kind).toBe("processing");
1085
+ expect(t.actions[3].verb).toBe("start_T3");
1086
+ expect(t.actions[3].kind).toBe("processing");
1087
+ expect(t.actions[4].verb).toBe("Select_T1_Value");
1088
+ expect(t.actions[4].kind).toBe("subroutine");
1089
+ expect(t.actions[5].verb).toBe("push_old_I_frame_N_r_on_queue");
1090
+ expect(t.actions[5].kind).toBe("internal_out");
1091
+ expect(t.actions[6].verb).toBe("LM_data_request");
1092
+ expect(t.actions[6].kind).toBe("signal_lower");
1093
+ expect(t.actions[7].verb).toBe("stop_T3");
1094
+ expect(t.actions[7].kind).toBe("processing");
1095
+ expect(t.actions[8].verb).toBe("start_T1");
1096
+ expect(t.actions[8].kind).toBe("processing");
1097
+ expect(t.actions[9].verb).toBe("clear_acknowledge_pending");
1098
+ expect(t.actions[9].kind).toBe("processing");
1099
+ });
1100
+ it("t61_srej_received_nr_in_window_pf_eq_1", () => {
1101
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t61_srej_received_nr_in_window_pf_eq_1");
1102
+ expect(t, "transition t61_srej_received_nr_in_window_pf_eq_1 not found").toBeDefined();
1103
+ if (!t)
1104
+ return;
1105
+ expect(t.on).toBe("SREJ_received");
1106
+ expect(t.next).toBe("Connected");
1107
+ expect(t.guard).toBe("V_a_le_N_r_le_V_s and P_or_F_eq_1");
1108
+ expect(t.actions).toHaveLength(11);
1109
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1110
+ expect(t.actions[0].kind).toBe("processing");
1111
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1112
+ expect(t.actions[1].kind).toBe("subroutine");
1113
+ expect(t.actions[2].verb).toBe("V(a) := N(r)");
1114
+ expect(t.actions[2].kind).toBe("processing");
1115
+ expect(t.actions[3].verb).toBe("stop_T1");
1116
+ expect(t.actions[3].kind).toBe("processing");
1117
+ expect(t.actions[4].verb).toBe("start_T3");
1118
+ expect(t.actions[4].kind).toBe("processing");
1119
+ expect(t.actions[5].verb).toBe("Select_T1_Value");
1120
+ expect(t.actions[5].kind).toBe("subroutine");
1121
+ expect(t.actions[6].verb).toBe("push_old_I_frame_N_r_on_queue");
1122
+ expect(t.actions[6].kind).toBe("internal_out");
1123
+ expect(t.actions[7].verb).toBe("LM_data_request");
1124
+ expect(t.actions[7].kind).toBe("signal_lower");
1125
+ expect(t.actions[8].verb).toBe("stop_T3");
1126
+ expect(t.actions[8].kind).toBe("processing");
1127
+ expect(t.actions[9].verb).toBe("start_T1");
1128
+ expect(t.actions[9].kind).toBe("processing");
1129
+ expect(t.actions[10].verb).toBe("clear_acknowledge_pending");
1130
+ expect(t.actions[10].kind).toBe("processing");
1131
+ });
1132
+ it("t62_srej_received_nr_out_of_window_v22", () => {
1133
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t62_srej_received_nr_out_of_window_v22");
1134
+ expect(t, "transition t62_srej_received_nr_out_of_window_v22 not found").toBeDefined();
1135
+ if (!t)
1136
+ return;
1137
+ expect(t.on).toBe("SREJ_received");
1138
+ expect(t.next).toBe("AwaitingConnection22");
1139
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and version_2_2");
1140
+ expect(t.actions).toHaveLength(3);
1141
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1142
+ expect(t.actions[0].kind).toBe("processing");
1143
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1144
+ expect(t.actions[1].kind).toBe("subroutine");
1145
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
1146
+ expect(t.actions[2].kind).toBe("subroutine");
1147
+ });
1148
+ it("t63_srej_received_nr_out_of_window_v20", () => {
1149
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t63_srej_received_nr_out_of_window_v20");
1150
+ expect(t, "transition t63_srej_received_nr_out_of_window_v20 not found").toBeDefined();
1151
+ if (!t)
1152
+ return;
1153
+ expect(t.on).toBe("SREJ_received");
1154
+ expect(t.next).toBe("AwaitingConnection");
1155
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and not version_2_2");
1156
+ expect(t.actions).toHaveLength(3);
1157
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1158
+ expect(t.actions[0].kind).toBe("processing");
1159
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1160
+ expect(t.actions[1].kind).toBe("subroutine");
1161
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
1162
+ expect(t.actions[2].kind).toBe("subroutine");
1163
+ });
1164
+ it("t64_rej_received_nr_in_window", () => {
1165
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t64_rej_received_nr_in_window");
1166
+ expect(t, "transition t64_rej_received_nr_in_window not found").toBeDefined();
1167
+ if (!t)
1168
+ return;
1169
+ expect(t.on).toBe("REJ_received");
1170
+ expect(t.next).toBe("Connected");
1171
+ expect(t.guard).toBe("V_a_le_N_r_le_V_s");
1172
+ expect(t.actions).toHaveLength(8);
1173
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1174
+ expect(t.actions[0].kind).toBe("processing");
1175
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1176
+ expect(t.actions[1].kind).toBe("subroutine");
1177
+ expect(t.actions[2].verb).toBe("V(a) := N(r)");
1178
+ expect(t.actions[2].kind).toBe("processing");
1179
+ expect(t.actions[3].verb).toBe("start_T1");
1180
+ expect(t.actions[3].kind).toBe("processing");
1181
+ expect(t.actions[4].verb).toBe("stop_T3");
1182
+ expect(t.actions[4].kind).toBe("processing");
1183
+ expect(t.actions[5].verb).toBe("clear_acknowledge_pending");
1184
+ expect(t.actions[5].kind).toBe("processing");
1185
+ expect(t.actions[6].verb).toBe("Select_T1_Value");
1186
+ expect(t.actions[6].kind).toBe("subroutine");
1187
+ expect(t.actions[7].verb).toBe("Invoke_Retransmission");
1188
+ expect(t.actions[7].kind).toBe("subroutine");
1189
+ });
1190
+ it("t65_rej_received_nr_out_of_window_v22", () => {
1191
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t65_rej_received_nr_out_of_window_v22");
1192
+ expect(t, "transition t65_rej_received_nr_out_of_window_v22 not found").toBeDefined();
1193
+ if (!t)
1194
+ return;
1195
+ expect(t.on).toBe("REJ_received");
1196
+ expect(t.next).toBe("AwaitingConnection22");
1197
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and version_2_2");
1198
+ expect(t.actions).toHaveLength(3);
1199
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1200
+ expect(t.actions[0].kind).toBe("processing");
1201
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1202
+ expect(t.actions[1].kind).toBe("subroutine");
1203
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
1204
+ expect(t.actions[2].kind).toBe("subroutine");
1205
+ });
1206
+ it("t66_rej_received_nr_out_of_window_v20", () => {
1207
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t66_rej_received_nr_out_of_window_v20");
1208
+ expect(t, "transition t66_rej_received_nr_out_of_window_v20 not found").toBeDefined();
1209
+ if (!t)
1210
+ return;
1211
+ expect(t.on).toBe("REJ_received");
1212
+ expect(t.next).toBe("AwaitingConnection");
1213
+ expect(t.guard).toBe("not V_a_le_N_r_le_V_s and not version_2_2");
1214
+ expect(t.actions).toHaveLength(3);
1215
+ expect(t.actions[0].verb).toBe("clear_peer_receiver_busy");
1216
+ expect(t.actions[0].kind).toBe("processing");
1217
+ expect(t.actions[1].verb).toBe("Check_Need_For_Response");
1218
+ expect(t.actions[1].kind).toBe("subroutine");
1219
+ expect(t.actions[2].verb).toBe("N_r_Error_Recovery");
1220
+ expect(t.actions[2].kind).toBe("subroutine");
1221
+ });
1222
+ it("t67_i_received_in_seq_stored_p_eq_1", () => {
1223
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t67_i_received_in_seq_stored_p_eq_1");
1224
+ expect(t, "transition t67_i_received_in_seq_stored_p_eq_1 not found").toBeDefined();
1225
+ if (!t)
1226
+ return;
1227
+ expect(t.on).toBe("I_received");
1228
+ expect(t.next).toBe("Connected");
1229
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and N_s_eq_V_r and V_r_I_frame_stored and P_eq_1");
1230
+ expect(t.actions).toHaveLength(12);
1231
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
1232
+ expect(t.actions[0].kind).toBe("subroutine");
1233
+ expect(t.actions[1].verb).toBe("V(r) := V(r) + 1");
1234
+ expect(t.actions[1].kind).toBe("processing");
1235
+ expect(t.actions[2].verb).toBe("clear_reject_exception");
1236
+ expect(t.actions[2].kind).toBe("processing");
1237
+ expect(t.actions[3].verb).toBe("decrement_srej_exception_if_gt_0");
1238
+ expect(t.actions[3].kind).toBe("processing");
1239
+ expect(t.actions[4].verb).toBe("DL_DATA_indication");
1240
+ expect(t.actions[4].kind).toBe("signal_upper");
1241
+ expect(t.actions[5].verb).toBe("retrieve_stored_V_r_I_frame");
1242
+ expect(t.actions[5].kind).toBe("processing");
1243
+ expect(t.actions[6].verb).toBe("DL_DATA_indication");
1244
+ expect(t.actions[6].kind).toBe("signal_upper");
1245
+ expect(t.actions[7].verb).toBe("V(r) := V(r) + 1");
1246
+ expect(t.actions[7].kind).toBe("processing");
1247
+ expect(t.actions[8].verb).toBe("F := 1");
1248
+ expect(t.actions[8].kind).toBe("processing");
1249
+ expect(t.actions[9].verb).toBe("N(r) := V(r)");
1250
+ expect(t.actions[9].kind).toBe("processing");
1251
+ expect(t.actions[10].verb).toBe("RR");
1252
+ expect(t.actions[10].kind).toBe("signal_lower");
1253
+ expect(t.actions[11].verb).toBe("clear_acknowledge_pending");
1254
+ expect(t.actions[11].kind).toBe("processing");
1255
+ });
1256
+ it("t68_i_received_in_seq_stored_p_eq_0_ack_pending", () => {
1257
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t68_i_received_in_seq_stored_p_eq_0_ack_pending");
1258
+ expect(t, "transition t68_i_received_in_seq_stored_p_eq_0_ack_pending not found").toBeDefined();
1259
+ if (!t)
1260
+ return;
1261
+ expect(t.on).toBe("I_received");
1262
+ expect(t.next).toBe("Connected");
1263
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and N_s_eq_V_r and V_r_I_frame_stored and not P_eq_1 and acknowledge_pending");
1264
+ expect(t.actions).toHaveLength(8);
1265
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
1266
+ expect(t.actions[0].kind).toBe("subroutine");
1267
+ expect(t.actions[1].verb).toBe("V(r) := V(r) + 1");
1268
+ expect(t.actions[1].kind).toBe("processing");
1269
+ expect(t.actions[2].verb).toBe("clear_reject_exception");
1270
+ expect(t.actions[2].kind).toBe("processing");
1271
+ expect(t.actions[3].verb).toBe("decrement_srej_exception_if_gt_0");
1272
+ expect(t.actions[3].kind).toBe("processing");
1273
+ expect(t.actions[4].verb).toBe("DL_DATA_indication");
1274
+ expect(t.actions[4].kind).toBe("signal_upper");
1275
+ expect(t.actions[5].verb).toBe("retrieve_stored_V_r_I_frame");
1276
+ expect(t.actions[5].kind).toBe("processing");
1277
+ expect(t.actions[6].verb).toBe("DL_DATA_indication");
1278
+ expect(t.actions[6].kind).toBe("signal_upper");
1279
+ expect(t.actions[7].verb).toBe("V(r) := V(r) + 1");
1280
+ expect(t.actions[7].kind).toBe("processing");
1281
+ });
1282
+ it("t69_i_received_in_seq_stored_p_eq_0_no_ack_pending", () => {
1283
+ const t = DataLinkConnected.transitions.find((x) => x.id === "t69_i_received_in_seq_stored_p_eq_0_no_ack_pending");
1284
+ expect(t, "transition t69_i_received_in_seq_stored_p_eq_0_no_ack_pending not found").toBeDefined();
1285
+ if (!t)
1286
+ return;
1287
+ expect(t.on).toBe("I_received");
1288
+ expect(t.next).toBe("Connected");
1289
+ expect(t.guard).toBe("command and info_field_valid and V_a_le_N_r_le_V_s and not own_receiver_busy and N_s_eq_V_r and V_r_I_frame_stored and not P_eq_1 and not acknowledge_pending");
1290
+ expect(t.actions).toHaveLength(10);
1291
+ expect(t.actions[0].verb).toBe("Check_I_Frame_Acknowledged");
1292
+ expect(t.actions[0].kind).toBe("subroutine");
1293
+ expect(t.actions[1].verb).toBe("V(r) := V(r) + 1");
1294
+ expect(t.actions[1].kind).toBe("processing");
1295
+ expect(t.actions[2].verb).toBe("clear_reject_exception");
1296
+ expect(t.actions[2].kind).toBe("processing");
1297
+ expect(t.actions[3].verb).toBe("decrement_srej_exception_if_gt_0");
1298
+ expect(t.actions[3].kind).toBe("processing");
1299
+ expect(t.actions[4].verb).toBe("DL_DATA_indication");
1300
+ expect(t.actions[4].kind).toBe("signal_upper");
1301
+ expect(t.actions[5].verb).toBe("retrieve_stored_V_r_I_frame");
1302
+ expect(t.actions[5].kind).toBe("processing");
1303
+ expect(t.actions[6].verb).toBe("DL_DATA_indication");
1304
+ expect(t.actions[6].kind).toBe("signal_upper");
1305
+ expect(t.actions[7].verb).toBe("V(r) := V(r) + 1");
1306
+ expect(t.actions[7].kind).toBe("processing");
1307
+ expect(t.actions[8].verb).toBe("LM_seize_request");
1308
+ expect(t.actions[8].kind).toBe("signal_lower");
1309
+ expect(t.actions[9].verb).toBe("set_acknowledge_pending");
1310
+ expect(t.actions[9].kind).toBe("processing");
1311
+ });
1312
+ });
1313
+ //# sourceMappingURL=connected.g.test.js.map