I'd like to make a suggestion.
In the TestMetaCoin.sol
example, you can see that the contract owner address is used. (See tx.origin
) Therefore, I see no reason why you couldn't hard-code other account addresses in a Solidity library file and then import the library into your test. You might be then be able to use $ testrpc --account="<privatekey>,balance" [--account="<privatekey>,balance"]
to ensure that the addresses in your library are re-used each time you launch.
You can do some fairly complicated things with Solidity tests. (See http://truffleframework.com/tutorials/testing-for-throws-in-solidity-tests) However, judging by the truffle docs, I get the impression that they may not be designed for your use case.
http://truffleframework.com/docs/getting_started/solidity-tests