Fix SpecFlow test

Don't send empty keys in PostData as this prevents the MVC ModelBinder
to work properly.

--HG--
branch : dev
This commit is contained in:
Renaud Paquay 2010-07-17 10:48:51 -07:00
parent 4988dbff06
commit 3bbc0854e6

View File

@ -194,6 +194,7 @@ namespace Orchard.Specs.Bindings {
.SelectMany(elt => elt.DescendantsAndSelf("input"))
.Where(node => !((node.GetAttributeValue("type", "") == "radio" || node.GetAttributeValue("type", "") == "checkbox") && node.GetAttributeValue("checked", "") != "checked"))
.GroupBy(elt => elt.GetAttributeValue("name", elt.GetAttributeValue("id", "")), elt => elt.GetAttributeValue("value", ""))
.Where(g => !string.IsNullOrEmpty(g.Key))
.ToDictionary(elt => elt.Key, elt => (IEnumerable<string>)elt);
Details = Host.SendRequest(urlPath, inputs);