Hi, > The test looks fine. Looking at your patch and at things some more i > wonder if it isn't eventually better to introduce a new hook - even > if it requires a new py.test release. Something like: > > # runs only on the master side > def pytest_xdist_configure_node(node): > node.slaveinput[NAME] = value > > # any hook or test can do the following manipulation > if hasattr(config, 'slavedata'): # means we are running slave side > config.slaveinput[NAME] # access data sent from the master > config.slaveoutput['result'] = 42 # set slave output > > # runs only on the master side > def pytest_xdist_nodedown(node, slaveoutput): > node.slaveoutput['result'] # access result from slave > > I think both internal implementation and usage becomes simpler. > What do you think?
It looks good. The hook names can be made consistent as well as consistent args. :) _______________________________________________ py-dev mailing list py-dev@codespeak.net http://codespeak.net/mailman/listinfo/py-dev