I'm not sure I understand. Because signals should not be sent in
certain
situations, we don't need to check this? Isn't the conclusion exactly
the opposite? Because the test script needs to work with a potentially
buggy server, it must do as much checking as possible and be prepared to
report server failures gracefully.
For a buggy server, it is possible.
But I think a correct server should not. So my suggestion is that we should
add at least one case to test this scenario: these signals should not be sent
out. This could make sure that our server at least has no this kind of error.
I merged everything related to this into master, including the fix
for
the StatusChanged "idle" problem. There are more patches pending in the
"pohly" branch, please let me know what you consider ready for merging.
One question, in the patch 'syncevo-dbus-server: StatusChanged "idle"
was not sent',
+ loop.run()
+ expected = ["session " + self.sessionpath + " done",
+ "session " + sessionpath + " idle",
+ "session " + sessionpath + " ready"]
+ expected.sort()
+ DBusUtil.quit_events.sort()
+ self.failUnlessEqual(DBusUtil.quit_events, expected)
I find expected and quit_events are all sorted. Don't we guarantee the sequence?
'progress' testing needs check the sequence problem.
Cheers,
Yongsheng
> -----Original Message-----
> From: Ohly, Patrick
> Sent: Friday, November 20, 2009 4:06 PM
> To: Zhu, Yongsheng
> Cc: SyncEvolution
> Subject: RE: [SyncEvolution] D-Bus Testing + TestSessionAPIsReal +
> StatusChanged "done" multiple times
>
> On Fri, 2009-11-20 at 03:11 +0000, Zhu, Yongsheng wrote:
> > > And it is really only sent once. The problem was in the test-dbus.py
> > > script. Here's the fix and a more detailed explanation:
> > When sync is done, signals of statusChanged and progressChanged should
> > be never sent. If has, I think it should be bugs of dbus server.
> > I doubt why we need this kind of checking.
>
I'm not sure I understand. Because signals should not be sent in
certain
situations, we don't need to check this? Isn't the conclusion exactly
the opposite? Because the test script needs to work with a potentially
buggy server, it must do as much checking as possible and be prepared to
report server failures gracefully.
>
> > > Yongsheng, I pushed this and a fix for sending SYNC_DONE at the end of
> > > Session::run() into "pohly". Please review.
> > It's ok.
>
I merged everything related to this into master, including the fix
for
the StatusChanged "idle" problem. There are more patches pending in the
"pohly" branch, please let me know what you consider ready for merging.
>
> --
> Best Regards, Patrick Ohly
>
> The content of this message is my personal opinion only and although
> I am an employee of Intel, the statements I make here in no way
> represent Intel's position on the issue, nor am I authorized to speak
> on behalf of Intel on this matter.
>