Skip to content

functional test for YANET2#237

Merged
moonug merged 20 commits intomainfrom
funtests
Sep 9, 2025
Merged

functional test for YANET2#237
moonug merged 20 commits intomainfrom
funtests

Conversation

@moonug
Copy link
Collaborator

@moonug moonug commented Aug 20, 2025

Add YANET Functional Testing Framework

Overview

This PR introduces a functional testing framework for YANET using QEMU virtual machines. The framework enables end-to-end testing of dataplane and controlplane modules in isolated environments.

Key Features

QEMU-based Testing

  • Isolated VM per test using Ubuntu 24.04 cloud image
  • Autologin via serial console
  • Cross-platform support (Linux/macOS)

Network Architecture

  • Unix domain sockets for packet transmission
  • Real network environment testing
  • Multiple network interface support

Integration

  • 9P filesystem sharing for build artifacts
  • VM executes real YANET processes from compiled binaries

Added Tests

  • Framework Test: Basic infrastructure validation
  • NAT64 Test: IPv4/IPv6 packet translation testing
  • Decap Test: IPIP6 tunnel decapsulation validation

Implementation

  • Thread-safe CLI command execution through serial console
  • Packet injection and capture via socket connections
  • Automatic VM lifecycle management with cleanup
  • Added test-functional target to build system

The framework provides reliable functional testing in real network environments with complete test isolation and easy extensibility for additional modules.

@moonug moonug marked this pull request as draft August 20, 2025 17:01
Konstantin Sazonov added 9 commits August 20, 2025 21:28
```
DEBUG   controlplane/mod.go:35  mapping shared memory   {"module": "forwardpb.ForwardService", "instances": [], "size": "16MB"}
VM output: panic: runtime error: index out of range [0] with length 0
```
@moonug moonug marked this pull request as ready for review September 1, 2025 12:08
@moonug moonug merged commit 7f420b3 into main Sep 9, 2025
6 checks passed
@moonug moonug deleted the funtests branch September 9, 2025 18:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants