简体   繁体   中英

General strategy for testing multi-thread system

Being asked this during a interview.

Nothing special come up with me except: start mutli threads, and feed the system with the prepared data, and then check if the output of the tested system is what we expected, it is some kind of integration test I think.

Are there any other ways/strategies to test?

Thanks

Functional test: Usually we have to verify that the threads are working properly with the common data (no data corruption when the simultaneous access). Also it is important to verify how the threads "talk" each with other (semaphores, events, etc.)

Non functional:

Security: Sometimes we are not provide the same level of access to the resources to threads. This is good practice but should be well verified.

Performance: Load test verifies how threads are working under load, you have to take the performance metrics separately from each thread.

Resilience: You want to verify how the threads will run in case if some of them will fail. It is important to verify that the main workers will continue run even without helper threads.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM