简体   繁体   中英

How to make an mstest project run another mstest project

Running .net 4.5

I have a single solution with multiple projects.

Some projects depend on other projects. I'd like my mstest projects to sort of mirror this.

So I have project1 and a test project for project1. I have project2 and a test project for project2. Project1 depends on project2.

When I run the mstest project for project1 I want it to also invoke the mstest project for project2. Does mstest support this? Project1 has a reference configured for project2 can an mstest project have a reference to another mstest project?

MStest projects are simply dlls that are scanned by the mstest.exe for test methods. The project itself cannot call another project. A script that scans for dlls and then executes mstest against all of them is the only way I know to do what you are asking.

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