Hi Felix,
This message did not appear in our framework.dev newsgroup, so I suspect
that there was probably a problem by sending, so I send it one more time.
First of all you will need to write an own InteractionHandler to write
the unit tests. It will be close to the implementation you have done
already, but this time in Java. The InteractionHandler should handle
only com.sun.star.task.MasterPasswordRequest.
A good example is the default implementation in uui/source/iahndl.cxx,
please just look for MasterPasswordRequest. The new implementation
should set a 32 character string containing 0-9 and a-z symbols ( this
is a digest, so it should contain hexadecimal digits ) to the continuation.
After the InteractionHandler implementation is ready it can be used to
write the tests. Please see some schematic scenario examples below.
scenario1:
- use XPasswordContainer::add() to add a set of users and passwords for
the same URL for runtime
- use XPasswordContainer::remove() to remove some of them
- use XPasswordContainer::find() to get the result and check it with the
expected one
- use XPasswordContainer::remove() to remove the runtime passwords
scenario2:
- use XMasterPasswordHandling::allowPersistentStoring( true ) to allow
the storing of the passwords
- use XPasswordContainer::addPersistent() to add a set of users and
passwords for the same URL persistently
- use XPasswordContainer::remove() to remove some of them
- use XPasswordContainer::find() to get the result and check it with the
expected one
- use XPasswordContainer::getAllPersistent() to check the result
- use XPasswordContainer::removeAllPersistent() to remove all the
persistent passwords
- use XPasswordContainer::remove() to remove the runtime passwords
- use XMasterPasswordHandling::allowPersistentStoring( false ) to
disallow the storing of the passwords
scenario3:
- use XMasterPasswordHandling::allowPersistentStoring( true ) to allow
the storing of the passwords
- use XPasswordContainer::addPersistent() to add a set of users and
passwords for the same URL persistently
- use XPasswordContainer::add() to add the same set of users with
different passwords for the same URL for runtime
- use XPasswordContainer::find() to get the result for the URL and check
that it contains persistent and runtime passwords ( will fail in the
current master )
- use XPasswordContainer::removeAllPersistent() to remove all the
persistent passwords
- use XPasswordContainer::remove() to remove the runtime passwords
- use XMasterPasswordHandling::allowPersistentStoring( false ) to
disallow the storing of the passwords
This is only a short description so the questions are as always welcome.
Best Regards,
Mikhail.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]