[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 15/23] tests/qtest: npcm7xx_emc-test: Skip running test_{tx, rx} o
From: |
Thomas Huth |
Subject: |
[PULL 15/23] tests/qtest: npcm7xx_emc-test: Skip running test_{tx, rx} on win32 |
Date: |
Tue, 30 Aug 2022 20:40:04 +0200 |
From: Bin Meng <bin.meng@windriver.com>
The test cases 'test_{tx,rx}' call socketpair() which does not exist
on win32. Exclude them.
Signed-off-by: Bin Meng <bin.meng@windriver.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20220824094029.1634519-44-bmeng.cn@gmail.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
tests/qtest/npcm7xx_emc-test.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/tests/qtest/npcm7xx_emc-test.c b/tests/qtest/npcm7xx_emc-test.c
index a353fef0ca..c373d24e1e 100644
--- a/tests/qtest/npcm7xx_emc-test.c
+++ b/tests/qtest/npcm7xx_emc-test.c
@@ -209,6 +209,7 @@ static int emc_module_index(const EMCModule *mod)
return diff;
}
+#ifndef _WIN32
static void packet_test_clear(void *sockets)
{
int *test_sockets = sockets;
@@ -243,6 +244,7 @@ static int *packet_test_init(int module_num, GString
*cmd_line)
g_test_queue_destroy(packet_test_clear, test_sockets);
return test_sockets;
}
+#endif /* _WIN32 */
static uint32_t emc_read(QTestState *qts, const EMCModule *mod,
NPCM7xxPWMRegister regno)
@@ -250,6 +252,7 @@ static uint32_t emc_read(QTestState *qts, const EMCModule
*mod,
return qtest_readl(qts, mod->base_addr + regno * sizeof(uint32_t));
}
+#ifndef _WIN32
static void emc_write(QTestState *qts, const EMCModule *mod,
NPCM7xxPWMRegister regno, uint32_t value)
{
@@ -339,6 +342,7 @@ static bool emc_soft_reset(QTestState *qts, const EMCModule
*mod)
g_message("%s: Timeout expired", __func__);
return false;
}
+#endif /* _WIN32 */
/* Check emc registers are reset to default value. */
static void test_init(gconstpointer test_data)
@@ -387,6 +391,7 @@ static void test_init(gconstpointer test_data)
qtest_quit(qts);
}
+#ifndef _WIN32
static bool emc_wait_irq(QTestState *qts, const EMCModule *mod, int step,
bool is_tx)
{
@@ -843,6 +848,7 @@ static void test_rx(gconstpointer test_data)
qtest_quit(qts);
}
+#endif /* _WIN32 */
static void emc_add_test(const char *name, const TestData* td,
GTestDataFunc fn)
@@ -865,8 +871,10 @@ int main(int argc, char **argv)
td->module = &emc_module_list[i];
add_test(init, td);
+#ifndef _WIN32
add_test(tx, td);
add_test(rx, td);
+#endif
}
return g_test_run();
--
2.31.1
- [PULL 07/23] tests/qtest: Build e1000e-test for posix only, (continued)
- [PULL 07/23] tests/qtest: Build e1000e-test for posix only, Thomas Huth, 2022/08/30
- [PULL 17/23] tests/vm: Add libslirp to the VM tests, Thomas Huth, 2022/08/30
- [PULL 19/23] tests/avocado: Fix trivial typo, Thomas Huth, 2022/08/30
- [PULL 01/23] tests/qtest: Use g_setenv(), Thomas Huth, 2022/08/30
- [PULL 18/23] tests/avocado: Do not run tests that require libslirp if it is not available, Thomas Huth, 2022/08/30
- [PULL 21/23] gitlab-ci: Only use one process in Windows jobs for compilation, Thomas Huth, 2022/08/30
- [PULL 22/23] tests/qtest/ac97-test: Correct reference to driver, Thomas Huth, 2022/08/30
- [PULL 12/23] tests/qtest: libqos: Rename malloc.h to libqos-malloc.h, Thomas Huth, 2022/08/30
- [PULL 14/23] tests/qtest: machine-none-test: Use double quotes to pass the cpu option, Thomas Huth, 2022/08/30
- [PULL 13/23] tests/qtest: device-plug-test: Reverse the usage of double/single quotes, Thomas Huth, 2022/08/30
- [PULL 15/23] tests/qtest: npcm7xx_emc-test: Skip running test_{tx, rx} on win32,
Thomas Huth <=
- [PULL 16/23] tests/qtest: prom-env-test: Use double quotes to pass the prom-env option, Thomas Huth, 2022/08/30
- [PULL 23/23] tests/avocado/migration: Get find_free_port() from the ports, Thomas Huth, 2022/08/30
- [PULL 20/23] docs/devel/testing: fix minor typo, Thomas Huth, 2022/08/30
- Re: [PULL 00/23] First testing patches for QEMU 7.2, Stefan Hajnoczi, 2022/08/31