Browse Source

integration-test: Fix the kernel version chceck for smoke test

Before this chane, the check was always negative if the minor version
was less then 9. So, for example, the smoke test was skipped for kernel
6.1:

```
skipping as 6.1 does not meet version requirement of 5.9
```

Signed-off-by: Michal Rostecki <[email protected]>
Michal Rostecki 2 years ago
parent
commit
75336e5a35
1 changed files with 1 additions and 1 deletions
  1. 1 1
      test/integration-test/src/tests/smoke.rs

+ 1 - 1
test/integration-test/src/tests/smoke.rs

@@ -19,7 +19,7 @@ fn xdp() {
 #[integration_test]
 #[integration_test]
 fn extension() {
 fn extension() {
     let (major, minor, _) = kernel_version().unwrap();
     let (major, minor, _) = kernel_version().unwrap();
-    if major < 5 || minor < 9 {
+    if major < 5 || (minor == 5 && minor < 9) {
         info!(
         info!(
             "skipping as {}.{} does not meet version requirement of 5.9",
             "skipping as {}.{} does not meet version requirement of 5.9",
             major, minor
             major, minor