What is the best way to unit test code that relies on you randomly generating data? I found this question on stack overflow but it is a little different. I know that you can use fixtures to mock out something like a database but I think that what I'm trying to do is a little different.
I'm trying to write an adaline neural network. This requires me to randomly generate weights and then the values for the weights are adjusted as more data is presented to the network. How do I unit test something like this? I've started writing tests for the parts that don't rely on random inputs, but I don't know how to handle this part.
Any suggestions would be appreciated.