That is, we no longer check that the final balance of the test account is correct; we would check that function in the unit test for the Transaction object, not the AtmGui object.
也就是说,我们不再检查测试帐户的最终余额是否正确;我们将在对Transaction对象的单元测试中检查该函数,而不是在对atmgui对象的单元测试中。
In the BankAccount example, the allowed values for an account balance, part of the account object's "state," are integral to the account object, not orthogonal to it.
在BankAccount示例中,帐户余额允许的值,即帐户对象“状态”的一部分,是帐户对象的一个有机部分,而不是与帐户对象的正交。
As an example to show how an alternative combination fragment is read, Figure 8 shows the sequence starting at the top, with the bank object getting the check's amount and the account's balance.
图8作为一个变体的组合碎片如何阅读的例子,显示序列从顶部开始,即bank对象获取支票金额和帐户结余。
应用推荐