Created
January 10, 2011 21:50
-
-
Save robashton/773534 to your computer and use it in GitHub Desktop.
Usage
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var session = AutoPocoContainer.CreateDefaultSession(); | |
var users = session.Collection<SimpleUser>(10, all => | |
{ | |
all.Random(5) | |
.Impose(x => x.FirstName, "Rob") | |
.Next(5) | |
.Impose(x => x.FirstName, "Scott"); | |
all.Random(5) | |
.Impose(x => x.LastName, "Red") | |
.Next(5) | |
.Impose(x => x.LastName, "Blue"); | |
}).ToList(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var session = AutoPocoContainer.CreateDefaultSession(); | |
var user = session.Next<SimpleUser>(all => | |
{ | |
all.Impose(x => x.FirstName, "Scott"); | |
all.Impose(x => x.LastName, "Hanselman"); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment