
Dan Smith wrote:
ZL> # HG changeset patch ZL> # User Zhengang Li <lizg@cn.ibm.com> ZL> # Date 1208344854 -28800 ZL> # Node ID 5d2e26fe8b594894946b95598aac5c43a6d3f0d0 ZL> # Parent e54b31ce89af19ca0d4c40ce4b097685e34aa2c7 ZL> [TEST] Retrieve revision and changeset string
ZL> The two properties can be accessed in test cases as ZL> 'main.revision', 'main.changeset'
This is a fine way to do this, but I'm curious: how will it impact the performance of the test suite? If we do this before every test, will it make the suite take a measurable amount of additional time to run?
These values won't change during a single run, so I had envisioned this being fetched once at the beginning and passed to each test case. That may not be feasible with the current architecture, so I have no real complaint here, I'm just wondering.
suites/libvirt-cim/main.py calls each testcase as an individual program, so nothing really gets persisted except for the few things that get set as environment variables. I had originally thought do try was a good way to go, but the other problem with this is that it forces libvirt-cim implementation details into lib/CimTest/Globals.py, which is mostly implementation agnostic. I suppose you could set these values as env variables, which would provider faster access than writing the values out to a file or something similar. We have a fair number of env vars already, and I don't want to rely on them. But this might be a good place to argue the use of them. =) -- Kaitlin Rupert IBM Linux Technology Center kaitlin@linux.vnet.ibm.com