You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@chemistry.apache.org by Alexey Zavizionov <al...@gmail.com> on 2010/02/25 18:02:46 UTC

TCK should check variables related to CMISUriTemplate

Hello!

The TCK tests should check that uri templates have appropriate variables.

=== related code ===
...
        CMISUriTemplate objectByIdTemplate =
client.getObjectByIdUriTemplate(client.getWorkspace());
        Map<String, Object> variables = new HashMap<String, Object>(5);
        variables.put("id", objectId);                 // <<< to check in
objectByIdTemplate
        variables.put("includeACL", "true");          // <<< to check in
objectByIdTemplate
        IRI objectByIdRequest = objectByIdTemplate.generateUri(variables);
...
=================

Regards,
Alexey.

Re: TCK should check variables related to CMISUriTemplate

Posted by Alexey Zavizionov <al...@gmail.com>.
The 2) should be at least, but the 1) would be great!

Here the issue https://issues.apache.org/jira/browse/CMIS-132

On Thu, Feb 25, 2010 at 7:58 PM, David Caruana
<da...@alfresco.com>wrote:

> Do you mean 1) test that the URI template has all variables as stated in
> the spec? or 2) that values should only be set for variables that exist
> within the URI template.
>
> It's my understanding that the spec requires all variables to specified in
> the URI template. So, implementing 1) makes sense.
>
> Dave
>
> On 25 Feb 2010, at 17:02, Alexey Zavizionov wrote:
>
> > Hello!
> >
> > The TCK tests should check that uri templates have appropriate variables.
> >
> > === related code ===
> > ...
> >        CMISUriTemplate objectByIdTemplate =
> > client.getObjectByIdUriTemplate(client.getWorkspace());
> >        Map<String, Object> variables = new HashMap<String, Object>(5);
> >        variables.put("id", objectId);                 // <<< to check in
> > objectByIdTemplate
> >        variables.put("includeACL", "true");          // <<< to check in
> > objectByIdTemplate
> >        IRI objectByIdRequest = objectByIdTemplate.generateUri(variables);
> > ...
> > =================
> >
> > Regards,
> > Alexey.
>
>

Re: TCK should check variables related to CMISUriTemplate

Posted by David Caruana <da...@alfresco.com>.
Do you mean 1) test that the URI template has all variables as stated in the spec? or 2) that values should only be set for variables that exist within the URI template.

It's my understanding that the spec requires all variables to specified in the URI template. So, implementing 1) makes sense.

Dave

On 25 Feb 2010, at 17:02, Alexey Zavizionov wrote:

> Hello!
> 
> The TCK tests should check that uri templates have appropriate variables.
> 
> === related code ===
> ...
>        CMISUriTemplate objectByIdTemplate =
> client.getObjectByIdUriTemplate(client.getWorkspace());
>        Map<String, Object> variables = new HashMap<String, Object>(5);
>        variables.put("id", objectId);                 // <<< to check in
> objectByIdTemplate
>        variables.put("includeACL", "true");          // <<< to check in
> objectByIdTemplate
>        IRI objectByIdRequest = objectByIdTemplate.generateUri(variables);
> ...
> =================
> 
> Regards,
> Alexey.