Skip to content

Commit

Permalink
tests: update testing snapshot
Browse files Browse the repository at this point in the history
Update expected snapshot test case for CFG diagram
  • Loading branch information
Raine-Yang-UofT committed Sep 26, 2024
1 parent 42a5338 commit ee18274
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 16 deletions.
16 changes: 8 additions & 8 deletions tests/test_cfg/snapshots/funcs_only.gv
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,29 @@ digraph funcs_only {
node [fontname="Courier New" shape=box]
subgraph cluster_0 {
cluster_0_0 [label="self\l" fillcolor=white style=filled]
cluster_0_0 -> cluster_0_2
cluster_0_0 -> cluster_0_2 [color=black]
cluster_0_2 [label="print('method')\l" fillcolor=white style=filled]
cluster_0_2 -> cluster_0_1
cluster_0_2 -> cluster_0_1 [color=black]
cluster_0_1 [label="\l" fillcolor=black style=filled]
fontname="Courier New" label="MyClass.foo"
}
subgraph cluster_1 {
cluster_1_0 [label="\l" fillcolor=white style=filled]
cluster_1_0 -> cluster_1_2
cluster_1_0 -> cluster_1_2 [color=black]
cluster_1_2 [label="a = 5\l" fillcolor=white style=filled]
cluster_1_2 -> cluster_1_1
cluster_1_2 -> cluster_1_1 [color=black]
cluster_1_1 [label="\l" fillcolor=black style=filled]
fontname="Courier New" label=foo
}
subgraph cluster_2 {
cluster_2_0 [label="\l" fillcolor=white style=filled]
cluster_2_0 -> cluster_2_2
cluster_2_0 -> cluster_2_2 [color=black]
cluster_2_2 [label="a > 0\l" fillcolor=white style=filled]
cluster_2_2 -> cluster_2_3 [label=True]
cluster_2_2 -> cluster_2_3 [label=True color=black]
cluster_2_3 [label="owl = 'hoo'\l" fillcolor=white style=filled]
cluster_2_3 -> cluster_2_1
cluster_2_3 -> cluster_2_1 [color=black]
cluster_2_1 [label="\l" fillcolor=black style=filled]
cluster_2_2 -> cluster_2_1 [label=False]
cluster_2_2 -> cluster_2_1 [label=False color=black]
fontname="Courier New" label=hoo
}
}
16 changes: 8 additions & 8 deletions tests/test_cfg/snapshots/my_file.gv
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@ digraph my_file {
node [fontname="Courier New" shape=box]
subgraph cluster_0 {
cluster_0_0 [label="\ldef foo() -> None:\l for i in range(1, 10):\l if i < 5:\l print('hi')\l" fillcolor=white style=filled]
cluster_0_0 -> cluster_0_1
cluster_0_0 -> cluster_0_1 [color=black]
cluster_0_1 [label="\l" fillcolor=black style=filled]
fontname="Courier New" label=__main__
}
subgraph cluster_1 {
cluster_1_0 [label="\l" fillcolor=white style=filled]
cluster_1_0 -> cluster_1_2
cluster_1_0 -> cluster_1_2 [color=black]
cluster_1_2 [label="range(1, 10)\l" fillcolor=white style=filled]
cluster_1_2 -> cluster_1_3
cluster_1_2 -> cluster_1_3 [color=black]
cluster_1_3 [label="i\l" fillcolor=white style=filled]
cluster_1_3 -> cluster_1_5
cluster_1_3 -> cluster_1_5 [color=black]
cluster_1_5 [label="i < 5\l" fillcolor=white style=filled]
cluster_1_5 -> cluster_1_6 [label=True]
cluster_1_5 -> cluster_1_6 [label=True color=black]
cluster_1_6 [label="print('hi')\l" fillcolor=white style=filled]
cluster_1_6 -> cluster_1_3
cluster_1_5 -> cluster_1_3 [label=False]
cluster_1_3 -> cluster_1_1
cluster_1_6 -> cluster_1_3 [color=black]
cluster_1_5 -> cluster_1_3 [label=False color=black]
cluster_1_3 -> cluster_1_1 [color=black]
cluster_1_1 [label="\l" fillcolor=black style=filled]
fontname="Courier New" label=foo
}
Expand Down

0 comments on commit ee18274

Please sign in to comment.