Skip to content

Add test for IPv4/IPv6 tunnel creation#552

Merged
lguohan merged 1 commit intosonic-net:masterfrom
stepanblyschak:tunnel_vs_test
Aug 10, 2018
Merged

Add test for IPv4/IPv6 tunnel creation#552
lguohan merged 1 commit intosonic-net:masterfrom
stepanblyschak:tunnel_vs_test

Conversation

@stepanblyschak
Copy link
Copy Markdown
Contributor

Signed-off-by: stepanb [email protected]

What I did
I added VS test for IPv4/IPv6 tunnel creation

Why I did it
There was no VS test for tunnel creation, so I added it

How I verified it
Run VS tests


tunnel_sai_obj = tunnels[0]

status, fvs = tunnel_table.get(tunnel_sai_obj)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we probably need to assert status == true here

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

expected_dscp_mode = self.dscp_modes_map[dscp_mode]
expected_ttl_mode = self.ttl_modes_map[ttl_mode]

for field, value in fvs:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need to access the len(fvs) since some attribute might be missing.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added assert len(fvs) == expected number of fields

Copy link
Copy Markdown
Contributor

@lguohan lguohan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add more checks

@stepanblyschak
Copy link
Copy Markdown
Contributor Author

Retest this please

1 similar comment
@lguohan
Copy link
Copy Markdown
Contributor

lguohan commented Aug 9, 2018

Retest this please

@lguohan lguohan merged commit d220a80 into sonic-net:master Aug 10, 2018
Janetxxx pushed a commit to Janetxxx/sonic-swss that referenced this pull request Nov 10, 2025
jianyuewu pushed a commit to jianyuewu/sonic-swss that referenced this pull request Dec 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants