The answer didn't exactly reflect my issue, but it got me thinking and 
after a few tests with various setups I got it working. Thanks a lot Brian:)

Den mandag den 5. november 2012 18.41.42 UTC+1 skrev Brian George:
>
> In AssemblyInfo.cs:
> [assembly: DegreeOfParallelism(3)]
> [assembly: Parallelizable(TestScope.All)]
>
> In Test file:
> [TestFixture]
>     [Parallelizable]
>
>     public class PTest
>     {
>         string[] search = new string[3] { "maps", "beer", "shoping" };
>         [DynamicTestFactory]
>         [Row("Google")]
>         [Row("Yahoo")]
>         public IEnumerable<Test> CreateDynamicTests(string searchProvider)
>         {
>             foreach (string searchTerm in search)
>             {
>                 yield return new TestCase("Search Term: " + searchTerm, () 
> =>
>                 {
>                     Console.WriteLine(DateTime.Now);
>                     Thread.Sleep(15000);
>                     Assert.IsNotNull(searchTerm);
>                 });
>             }
>         }
>     }
>
> I get the following results:
>
>    - PTest   
>    [image: Passed]8[image: Failed]0[image: Inconclusive or Skipped]0 
>    Duration: 45.233s, Assertions: 6. 
>     - CreateDynamicTests   
>       [image: Passed]8[image: Failed]0[image: Inconclusive or Skipped]0 
>       Duration: 45.200s, Assertions: 6. 
>        - CreateDynamicTests("Google")   
>          [image: Passed]4[image: Failed]0[image: Inconclusive or Skipped]0 
>          Duration: 45.037s, Assertions: 3. 
>           - Search Term: maps   
>             Duration: 15.023s, Assertions: 1. 
>              11/5/2012 9:37:23 AM
>             - Search Term: beer   
>             Duration: 15.000s, Assertions: 1. 
>              11/5/2012 9:37:38 AM
>             - Search Term: shoping   
>             Duration: 15.000s, Assertions: 1. 
>              11/5/2012 9:37:53 AM
>             - CreateDynamicTests("Yahoo")   
>          [image: Passed]4[image: Failed]0[image: Inconclusive or Skipped]0 
>          Duration: 45.036s, Assertions: 3. 
>           - Search Term: maps   
>             Duration: 15.023s, Assertions: 1. 
>              11/5/2012 9:37:23 AM
>             - Search Term: beer   
>             Duration: 15.000s, Assertions: 1. 
>              11/5/2012 9:37:38 AM
>             - Search Term: shoping   
>             Duration: 15.000s, Assertions: 1. 
>              11/5/2012 9:37:53 AM
>             
> It shows 2 tests running at the same time.
>
> Brian
>
> On Monday, November 5, 2012 2:34:45 AM UTC-8, Mikkel Pedersen Kaas wrote:
>>
>> I've had a paralleled version in the past, but now that I'm rewriting it, 
>> it doesn't seem to be working anymore. 
>>
>> I'm using a [DynamicTestFactory], within which I'm creating a TestSuite. 
>> I then add additional TestSuites and TestCases to it. It's these tests that 
>> I'd like to execute in parallel, but I'm unsure of how to go about it. 
>>
>> Den onsdag den 31. oktober 2012 23.50.13 UTC+1 skrev Brian George:
>>>
>>> In the AssemblyInfo.cs file: 
>>> [assembly: DegreeOfParallelism(3)]
>>> [assembly: Parallelizable(TestScope.All)]
>>>
>>> Also be sure to add [Parallelizable] to your TestFixture
>>>
>>>
>>> http://www.seleniumwiki.com/software-testing/selenium-grid/installing-selenium-grid-with-mbunit-and-gallio
>>>  
>>>
>>> Brian
>>>
>>>
>>> On Monday, October 29, 2012 3:55:45 AM UTC-7, Mikkel Pedersen Kaas wrote:
>>>>
>>>> Hi,
>>>>
>>>> I'm using Selenium and c# to make some, for the time being, simple 
>>>> tests of a few webpages. Right now I'm using a DynamicTestFactory to 
>>>> create 
>>>> a test for each page with each different browser that we aim to support. 
>>>> My 
>>>> problem is, that I can't figure out how to make the tests generated by the 
>>>> DynamicTestFactory execute in parallel. Is there anyone that can shed some 
>>>> light on the issue? Thank you. 
>>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"MbUnit.User" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/mbunituser/-/eWPlYO4mor0J.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/mbunituser?hl=en.

Reply via email to