Commit 10e8d5b8fa705b2aa42472293c8530181d5aebca

Authored by Antonio Castillo Verdugo
1 parent f55867df

- New function: f_cse_createResource_cseSimu

- New Annc templates
- New Annc constants
- Functions updated: f_CSE_DMR_CRE_001_cseSimu, f_CSE_DMR_CRE_019
- Testcases updated: TC_CSE_DMR_CRE_001_SUB_AEA, TC_CSE_DMR_CRE_001_CNT_AEA, TC_CSE_DMR_CRE_001_GRP_AEA, TC_CSE_DMR_CRE_001_ACP_AEA, TC_CSE_DMR_CRE_019_CNTA_AEA, TC_CSE_DMR_CRE_019_GRPA_AEA, TC_CSE_DMR_CRE_019_ACPA_AEA
- New testcases: TC_CSE_DMR_CRE_001_TS_AEA, TC_CSE_DMR_UPD_017_TS, TC_CSE_DMR_UPD_017_TSI, TC_CSE_DMR_UPD_018_TS_MBS, TC_CSE_DMR_CRE_019_TSA_AEA

Signed-off-by: acverdugo <acverdugo@at4wireless.com>
... ... @@ -2513,6 +2513,55 @@ module OneM2M_Functions {
2513 2513 }
2514 2514  
2515 2515 }//End of function
  2516 +
  2517 + /**
  2518 + * @desc Creation of a resource using CseSimu
  2519 + * @param p_resourceType Resource type of the resource to be created
  2520 + * @param p_requestPrimitive CREATE request primitive for the resource to be created
  2521 + * @param p_parentIndex Internal resource index which indicates the parent of the resource to be created
  2522 + * @return Internal resource index of the created resource
  2523 + * @verdict
  2524 + */
  2525 + function f_cse_createResource_cseSimu(in ResourceType p_resourceType, template RequestPrimitive p_requestPrimitive := m_create, integer p_parentIndex := -1) runs on CseSimu return integer {
  2526 +
  2527 + var RequestPrimitive v_request;
  2528 + var integer v_resourceIndex := -1;
  2529 +
  2530 + //Activate defaults when running on a PTC
  2531 + f_cse_activateDefaults_cse1();
  2532 +
  2533 + v_request := f_getCreateRequestPrimitive(p_resourceType, p_requestPrimitive, p_parentIndex);
  2534 +
  2535 + mccPort.send(f_getMsgOutPrimitive(m_request(v_request)));
  2536 + tc_ac.start;
  2537 + alt {
  2538 + [] mccPort.receive(mw_response(mw_responsePrimitiveOK)) -> value vc_response {
  2539 + tc_ac.stop;
  2540 + setverdict(pass, __SCOPE__&":INFO: Resource type " & int2str(enum2int(p_resourceType)) & " created successfuly");
  2541 + f_checkAttributesToBeSaved(p_resourceType, v_request, vc_response.primitive.responsePrimitive);
  2542 + v_resourceIndex := f_setResource(vc_response.primitive.responsePrimitive.primitiveContent, p_resourceType, p_parentIndex);
  2543 + if(p_resourceType == int16) { //remoteCSE
  2544 + vc_remoteCseIndex := v_resourceIndex;
  2545 + }
  2546 + }
  2547 + [] mccPort.receive(mw_response(mw_responsePrimitiveKO)) {
  2548 + tc_ac.stop;
  2549 + setverdict(inconc, __SCOPE__&":INFO: Error while creating resource type " & int2str(enum2int(p_resourceType)));
  2550 + }
  2551 + [] mccPort.receive {
  2552 + tc_ac.stop;
  2553 + setverdict(inconc, __SCOPE__&":INFO: Unexpected message received");
  2554 + }
  2555 + [] tc_ac.timeout {
  2556 + setverdict(inconc, __SCOPE__&":INFO: No answer while creating resource type " & int2str(enum2int(p_resourceType)));
  2557 + }
  2558 + }
  2559 +
  2560 + f_checkCseSimuStatus();
  2561 +
  2562 + return v_resourceIndex;
  2563 +
  2564 + }
2516 2565  
2517 2566 /**
2518 2567 * @desc Send response to the IUT (Test System simulating a CSE)
... ...
... ... @@ -791,6 +791,15 @@ module OneM2M_Templates {
791 791 resourceType := int1,
792 792 primitiveContent := {accessControlPolicy := m_contentCreateAcp ()}
793 793 };
  794 +
  795 + /**
  796 + * @desc Base CREATE request primitive for AccessControlPolicyAnnc resource
  797 + */
  798 + template (value) RequestPrimitive m_createAcpAnncBase modifies m_create := {
  799 + requestIdentifier := testcasename() & "-m_createAcpAnnc",
  800 + resourceType := int10001,
  801 + primitiveContent := {accessControlPolicyAnnc := m_contentCreateAcpAnnc ()}
  802 + };
794 803  
795 804 template (value) RequestPrimitive m_createAcp(XSD.ID p_parentResourceAddress, in template (omit) XSD.String p_name := c_defaultAccessControlPolicyResourceName, in template (value) ListOfURIs p_acor := PX_ACOR, in template (value) AccessControlOperations p_allowedOperations := int63) modifies m_create := {
796 805 to_ := p_parentResourceAddress,
... ... @@ -851,6 +860,15 @@ module OneM2M_Templates {
851 860 resourceType := int3,
852 861 primitiveContent := {container := m_contentCreateContainer}
853 862 };
  863 +
  864 + /**
  865 + * @desc Base CREATE request primitive for ContainerAnnc resource
  866 + */
  867 + template (value) RequestPrimitive m_createContainerAnncBase modifies m_create := {
  868 + requestIdentifier := testcasename() & "-m_createContainerAnnc",
  869 + resourceType := int10003,
  870 + primitiveContent := {containerAnnc := m_contentCreateContainerAnnc}
  871 + };
854 872  
855 873 /**
856 874 * @desc Base CREATE request primitive for Container resource using Container_update_invalid
... ... @@ -998,6 +1016,15 @@ module OneM2M_Templates {
998 1016 resourceType := int9,
999 1017 primitiveContent := {group_ := m_contentCreateGroup (1, {"NotInitialized"}, omit, omit)} //TODO: p_resourceId
1000 1018 };
  1019 +
  1020 + /**
  1021 + * @desc Base CREATE request primitive for GroupAnnc resource
  1022 + */
  1023 + template (value) RequestPrimitive m_createGroupAnncBase modifies m_create := {
  1024 + requestIdentifier := testcasename() & "-m_createGroupAnnc",
  1025 + resourceType := int10009,
  1026 + primitiveContent := {groupAnnc := m_contentCreateGroupAnnc (1, {"NotInitialized"}, omit, omit)} //TODO: p_resourceId
  1027 + };
1001 1028  
1002 1029 template (value) RequestPrimitive m_createGroup(in template (value) XSD.NonNegativeInteger p_maxNrOfMembers,
1003 1030 in template (value) ListOfURIs p_memberIds := {"NotInitialized"},
... ... @@ -1286,6 +1313,15 @@ module OneM2M_Templates {
1286 1313 resourceType := int29,
1287 1314 primitiveContent := {timeSeries := m_contentCreateTimeSeries ()}
1288 1315 };
  1316 +
  1317 + /**
  1318 + * @desc Base CREATE request primitive for timeSeriesAnnc resource
  1319 + */
  1320 + template (value) RequestPrimitive m_createTimeSeriesAnncBase modifies m_create := {
  1321 + requestIdentifier := testcasename() & "-m_createTimeSeriesAnnc",
  1322 + resourceType := int10029,
  1323 + primitiveContent := {timeSeriesAnnc := m_contentCreateTimeSeriesAnnc()}
  1324 + };
1289 1325  
1290 1326 template (value) RequestPrimitive m_createTimeSeries(in template (omit) XSD.String p_name := c_defaultTimeSeriesResourceName,
1291 1327 in XSD.Boolean p_missingDataDetect := true,
... ... @@ -1717,6 +1753,31 @@ module OneM2M_Templates {
1717 1753 };
1718 1754  
1719 1755 /**
  1756 + * @desc Base primitiveContent for CREATE operation for AccessControlPolicyAnnc resource
  1757 + * @param p_name Resource name
  1758 + * @param p_acor Allowed originators
  1759 + * @param p_allowedOperations Allowed operations
  1760 + */
  1761 + template (value) AccessControlPolicyAnnc_optional m_contentCreateAcpAnnc (in template (omit) XSD.String p_name := c_defaultAccessControlPolicyAnncResourceName, in template (value) ListOfURIs p_acor := PX_ACOR, in template (value) AccessControlOperations p_allowedOperations := int63 ) := {
  1762 + resourceName := p_name,//O
  1763 + resourceType := omit,//NP
  1764 + resourceID := omit,//NP
  1765 + parentID := omit,//NP
  1766 + creationTime := omit,//NP
  1767 + lastModifiedTime := omit,//NP
  1768 + labels := omit,//O
  1769 + expirationTime := omit,//O
  1770 + link := omit,//M TODO Put the right value
  1771 + privileges := {
  1772 + accessControlRule_list := {valueof(m_createAcr(p_acor, p_allowedOperations))}
  1773 + },//M
  1774 + selfPrivileges := {
  1775 + accessControlRule_list := {valueof(m_createAcr({"all"}, int63))}
  1776 + },//M
  1777 + choice := omit //NP
  1778 + };
  1779 +
  1780 + /**
1720 1781 * @desc Base reception template of primitiveContent for CREATE operation for AccessControlPolicyAnnc resource
1721 1782 * @param p_labels Labels
1722 1783 */
... ... @@ -1862,6 +1923,43 @@ module OneM2M_Templates {
1862 1923 choice := omit//NP
1863 1924 };
1864 1925  
  1926 + /**
  1927 + * @desc Base primitiveContent for CREATE operation for GroupAnnc resource
  1928 + * @param p_maxNrOfMembers Max number of members
  1929 + * @param p_memberIds Member IDs
  1930 + * @param p_accessControlPolicyIds ACP IDs for the GroupAnnc
  1931 + * @param p_name Resource name
  1932 + */
  1933 + template (value) GroupAnnc_optional m_contentCreateGroupAnnc ( in template (value) XSD.PositiveInteger p_maxNrOfMembers,
  1934 + in template (value) ListOfURIs p_memberIds,
  1935 + in template (omit) AcpType p_accessControlPolicyIds,
  1936 + in template (omit) MemberType p_memberType := omit,
  1937 + in template (omit) ConsistencyStrategy p_consistencyStrategy := omit,
  1938 + in template (omit) ListOfURIs p_membersAccessControlPolicyIDs := omit,
  1939 + in template (omit) XSD.String p_name := c_defaultGroupAnncResourceName) := {
  1940 + resourceName := p_name,//O
  1941 + resourceType := omit,//NP
  1942 + resourceID := omit,//NP
  1943 + parentID := omit,//NP
  1944 + creationTime := omit,//NP
  1945 + lastModifiedTime := omit,//NP
  1946 + labels := omit,//O
  1947 + accessControlPolicyIDs := p_accessControlPolicyIds,//O
  1948 + expirationTime := omit,//O
  1949 + link := omit,//M TODO Put the right value
  1950 + dynamicAuthorizationConsultationIDs := omit, //O
  1951 + memberType := p_memberType,//O
  1952 + currentNrOfMembers := omit,//NP
  1953 + maxNrOfMembers := p_maxNrOfMembers,//M
  1954 + memberIDs := p_memberIds,//M
  1955 + membersAccessControlPolicyIDs := p_membersAccessControlPolicyIDs,//O
  1956 + memberTypeValidated := omit,//NP
  1957 + consistencyStrategy := p_consistencyStrategy,//O
  1958 + groupName := omit,//O
  1959 + semanticSupportIndicator := omit,//O
  1960 + choice := omit//NP
  1961 + };
  1962 +
1865 1963 /**
1866 1964 * @desc Base reception template of primitiveContent for CREATE operation for GroupAnnc resource
1867 1965 */
... ... @@ -2250,6 +2348,34 @@ module OneM2M_Templates {
2250 2348 };
2251 2349  
2252 2350 /**
  2351 + * @desc Base primitiveContent for CREATE operation for ContainerAnnc resource
  2352 + * @param p_name Resource name
  2353 + */
  2354 + template (value) ContainerAnnc_optional m_contentCreateContainerAnnc (in template (omit) XSD.String p_name := c_defaultContainerAnncResourceName):= {
  2355 + resourceName := p_name,//O
  2356 + resourceType := omit,//NP
  2357 + resourceID := omit,//NP
  2358 + parentID := omit,//NP
  2359 + creationTime := omit,//NP
  2360 + lastModifiedTime := omit,//NP
  2361 + labels := omit,//O
  2362 + accessControlPolicyIDs := omit,//O
  2363 + expirationTime := omit,//O
  2364 + link := omit,//M TODO Put the right value
  2365 + dynamicAuthorizationConsultationIDs := omit, //O
  2366 + stateTag := omit,//NP
  2367 + maxNrOfInstances := omit,//O
  2368 + maxByteSize := omit,//O
  2369 + maxInstanceAge := omit,//O
  2370 + currentNrOfInstances := omit,//NP
  2371 + currentByteSize := omit,//NP
  2372 + locationID := omit,//O
  2373 + ontologyRef := omit,//O
  2374 + disableRetrieval := omit, //O
  2375 + choice := omit//NP
  2376 + };
  2377 +
  2378 + /**
2253 2379 * @desc Base primitiveContent for invalid CREATE operation for Container resource (using Container_update_invalid)
2254 2380 * @param p_name Resource name
2255 2381 */
... ... @@ -2569,7 +2695,7 @@ module OneM2M_Templates {
2569 2695 };
2570 2696  
2571 2697 /**
2572   - * @desc Base primitiveContent for CREATE operation for timeSeries resource
  2698 + * @desc Base primitiveContent for CREATE operation for timeSeries resource
2573 2699 * @param p_name Resource name
2574 2700 */
2575 2701 template (value) TimeSeries_optional m_contentCreateTimeSeries (in template (omit) XSD.String p_name := c_defaultTimeSeriesResourceName):= {
... ... @@ -2603,6 +2729,37 @@ module OneM2M_Templates {
2603 2729 };
2604 2730  
2605 2731 /**
  2732 + * @desc Base primitiveContent for CREATE operation for timeSeriesAnnc resource
  2733 + * @param p_name Resource name
  2734 + */
  2735 + template (value) TimeSeriesAnnc_optional m_contentCreateTimeSeriesAnnc (in template (omit) XSD.String p_name := c_defaultTimeSeriesAnncResourceName):= {
  2736 + resourceName := p_name,//O
  2737 + resourceType := omit,//NP
  2738 + resourceID := omit,//NP
  2739 + parentID := omit,//NP
  2740 + creationTime := omit,//NP
  2741 + lastModifiedTime := omit,//NP
  2742 + labels := omit,//O
  2743 + accessControlPolicyIDs := omit,//O
  2744 + expirationTime := omit,//O
  2745 + link := omit,//M TODO Put the right value
  2746 + dynamicAuthorizationConsultationIDs := omit, //O
  2747 + stateTag := omit,//NP
  2748 + maxNrOfInstances := omit,//O
  2749 + maxByteSize := omit,//O
  2750 + maxInstanceAge := omit,//O
  2751 + currentNrOfInstances := omit,//NP
  2752 + currentByteSize := omit,//NP
  2753 + periodicInterval := omit,//O
  2754 + missingDataDetect := omit,//O
  2755 + missingDataList := omit,//NP
  2756 + missingDataCurrentNr := omit,//NP
  2757 + missingDataDetectTimer := omit,//O
  2758 + ontologyRef := omit,//O
  2759 + choice := omit//NP
  2760 + };
  2761 +
  2762 + /**
2606 2763 * @desc Base primitiveContent for CREATE operation for TimeSeriesAnnc resource
2607 2764 * @param p_primitiveContent Content for the TimeSeriesAnnc
2608 2765 */
... ... @@ -2668,6 +2825,7 @@ module OneM2M_Templates {
2668 2825 missingDataMaxNr := p_missingDataMaxNr,//O
2669 2826 missingDataDetectTimer := p_missingDataDetectTimer//O
2670 2827 }
  2828 +
2671 2829 /**
2672 2830 * @desc Base primitiveContent for invalid CREATE operation for timeSeries resource (using Container_update_invalid)
2673 2831 * @param p_name Resource name
... ...
... ... @@ -18,12 +18,15 @@ module OneM2M_TypesAndValues {
18 18 /* Constants */
19 19 const XSD.String c_defaultResourceName := "MyResource";
20 20 const XSD.String c_defaultGroupResourceName := "MyGroupResource";
  21 + const XSD.String c_defaultGroupAnncResourceName := "MyGroupAnncResource";
21 22 const XSD.String c_defaultAccessControlPolicyResourceName := "MyAccessControlPolicyResource";
  23 + const XSD.String c_defaultAccessControlPolicyAnncResourceName := "MyAccessControlPolicyAnncResource";
22 24 const XSD.String c_defaultScheduleResourceName := "MyScheduleResource";
23 25 const XSD.String c_defaultPollingChannelResourceName := "MyPollingChannelResource";
24 26 const XSD.String c_defaultSubscriptionResourceName := "MySubscriptionResource";
25 27 const XSD.String c_defaultContentInstanceResourceName := "MyContentInstanceResource";
26 28 const XSD.String c_defaultContainerResourceName := "MyContainerResource";
  29 + const XSD.String c_defaultContainerAnncResourceName := "MyContainerAnncResource";
27 30 const XSD.String c_defaultDeliveryResourceName := "MyDeliveryResource";
28 31 const XSD.String c_defaultRemoteCSEResourceName := "MyRemoteCSEResource";
29 32 const XSD.String c_defaultMgmtObjResourceName := "MyMgmtObjResource";
... ... @@ -38,6 +41,7 @@ module OneM2M_TypesAndValues {
38 41 const XSD.String c_defaultm2mServiceSubscriptionProfileResourceName := "Mym2mServiceSubscriptionProfileResource";
39 42 const XSD.String c_defaultServiceSubscribedAppRuleResourceName := "MyServiceSubscribedAppRuleResource";
40 43 const XSD.String c_defaultTimeSeriesResourceName := "MyTimeSeriesResource";
  44 + const XSD.String c_defaultTimeSeriesAnncResourceName := "MyTimeSeriesAnncResource";
41 45 const XSD.String c_defaultTimeSeriesInstanceResourceName := "MyTimeSeriesInstanceResource";
42 46 const XSD.ID c_aeAuxName := "MyAe";
43 47 const XSD.String c_defaultAE2Name := "MyAe2";
... ...
... ... @@ -1919,81 +1919,85 @@ module OneM2M_PermutationFunctions {
1919 1919  
1920 1920 }//end f_CSE_DMR_CRE_001
1921 1921  
1922   - function f_CSE_DMR_CRE_001_cseSimu(ResourceType p_resourceType, template RequestPrimitive p_requestPrimitive) runs on CseSimu return ResponsePrimitive {
  1922 + function f_CSE_DMR_CRE_001_cseSimu(ResourceType p_resourceType, template RequestPrimitive p_requestPrimitive, ResourceType p_parentResourceType := int2, in template (omit) RequestPrimitive p_parentRequestPrimitive := omit) runs on CseSimu{
1923 1923  
1924   - // Local variables
1925   - var MsgIn v_response;
1926   - var RequestPrimitive v_request;
1927   - var integer v_parentIndex := -1;
1928   - var integer v_resourceIndex := -1;
1929   - var integer v_ae1Index := -1;
1930   - var integer v_acpAuxIndex := -1;
1931   - var PoaList v_poaList := {"http://" & PX_AE1_ADDRESS & "/"};
1932   -
1933   - // Test control
1934   -
1935   - // Test component configuration
1936   - f_cf02UpCseSimuMaster();
  1924 + // Local variables
  1925 + var MsgIn v_response;
  1926 + var RequestPrimitive v_request;
  1927 + var integer v_parentIndex := -1;
  1928 + var integer v_resourceIndex := -1;
  1929 + var integer v_ae1Index := -1;
  1930 + var integer v_acpAuxIndex := -1;
  1931 + var PoaList v_poaList := {"http://" & PX_AE1_ADDRESS & "/"};
  1932 +
  1933 + // Test control
  1934 +
  1935 + // Test component configuration
  1936 + f_cf02UpCseSimuMaster();
  1937 +
  1938 + // Test adapter configuration
  1939 +
  1940 + // Preamble
  1941 + vc_remoteCseIndex := f_cse_registerRemoteCse(m_createRemoteCSEBase);
1937 1942  
1938   - // Test adapter configuration
1939   -
1940   - // Preamble
1941   - vc_remoteCseIndex := f_cse_registerRemoteCse(m_createRemoteCSEBase);
1942   -
1943   - if(match(int23, p_resourceType)){
1944   - vc_ae1.start(f_cse_preamble_createAcpAux("SubscriptionVerificationAcp", int63));
1945   - f_cseSimu_checkComponentDoneAndGetVerdict(vc_ae1);
1946   - vc_ae1.start(f_cse_createResource_withAcpAux(int2, m_createAe(PX_APP_ID, -, PX_AE1_ID_STEM, "MyAe", v_poaList), -1)); // AE1 is registered
1947   - f_cseSimu_checkComponentDoneAndGetVerdict(vc_ae1);
1948   - v_ae1Index := f_getResource(vc_ae1);
1949   - p_requestPrimitive.primitiveContent.subscription.notificationURI := {f_getResourceAddress(v_ae1Index)};
1950   - vc_ae1.start(f_cse_notifyProcedure_subscriptionVerificationHandler());
1951   - }
1952   -
1953   - // Test Body
1954   -
1955   - v_request := f_getCreateRequestPrimitive(p_resourceType, p_requestPrimitive, vc_remoteCseIndex);
  1943 + if(match(int23, p_resourceType)){
  1944 + vc_ae1.start(f_cse_preamble_createAcpAux("SubscriptionVerificationAcp", int63));
  1945 + f_cseSimu_checkComponentDoneAndGetVerdict(vc_ae1);
  1946 + vc_ae1.start(f_cse_createResource_withAcpAux(int2, m_createAe(PX_APP_ID, -, PX_AE1_ID_STEM, "MyAe", v_poaList), -1)); // AE1 is registered
  1947 + f_cseSimu_checkComponentDoneAndGetVerdict(vc_ae1);
  1948 + v_ae1Index := f_getResource(vc_ae1);
  1949 + p_requestPrimitive.primitiveContent.subscription.notificationURI := {f_getResourceAddress(v_ae1Index)};
  1950 + vc_ae1.start(f_cse_notifyProcedure_subscriptionVerificationHandler());
  1951 + }
1956 1952  
1957   - mccPort.send(f_getMsgOutPrimitive(m_request(v_request)));
1958   - tc_ac.start;
1959   - alt {
1960   - [] mccPort.receive(mw_response(mw_responsePrimitive(int2001))) -> value vc_response {
1961   - tc_ac.stop;
1962   - setverdict(pass, __SCOPE__ & ": Resource type " & int2str(enum2int(p_resourceType)) & " created successfully");
1963   - f_checkAttributesToBeSaved(p_resourceType, v_request, vc_response.primitive.responsePrimitive);
1964   - v_resourceIndex := f_setResource(vc_response.primitive.responsePrimitive.primitiveContent, p_resourceType, vc_remoteCseIndex);
1965   - }
1966   - [] mccPort.receive(mw_response(mw_responsePrimitiveOK)) -> value vc_response {
1967   - tc_ac.stop;
1968   - setverdict(fail, __SCOPE__ & ": Wrong response status code");
1969   - }
1970   - [] mccPort.receive(mw_response(mw_responsePrimitiveKO)) -> value vc_response {
1971   - tc_ac.stop;
1972   - setverdict(fail, __SCOPE__ & ": Error while creating resource type " & int2str(enum2int(p_resourceType)));
1973   - }
1974   - [] tc_ac.timeout {
1975   - setverdict(fail, __SCOPE__ & ": No answer while creating resource type " & int2str(enum2int(p_resourceType)));
  1953 + if (not ispresent(p_parentRequestPrimitive)){ //Create the resource directly under RemoteCSE
  1954 + v_parentIndex := vc_remoteCseIndex;
  1955 + }else{ //Create the resource under parentResource
  1956 + v_parentIndex := f_cse_createResource_cseSimu(p_parentResourceType, p_parentRequestPrimitive, vc_remoteCseIndex);
  1957 + }
  1958 +
  1959 + // Test Body
  1960 +
  1961 + v_request := f_getCreateRequestPrimitive(p_resourceType, p_requestPrimitive, v_parentIndex);
  1962 +
  1963 + mccPort.send(f_getMsgOutPrimitive(m_request(v_request)));
  1964 + tc_ac.start;
  1965 + alt {
  1966 + [] mccPort.receive(mw_response(mw_responsePrimitive(int2001))) -> value vc_response {
  1967 + tc_ac.stop;
  1968 + setverdict(pass, __SCOPE__ & ": Resource type " & int2str(enum2int(p_resourceType)) & " created successfully");
  1969 + f_checkAttributesToBeSaved(p_resourceType, v_request, vc_response.primitive.responsePrimitive);
  1970 + v_resourceIndex := f_setResource(vc_response.primitive.responsePrimitive.primitiveContent, p_resourceType, v_parentIndex);
  1971 + }
  1972 + [] mccPort.receive(mw_response(mw_responsePrimitiveOK)) -> value vc_response {
  1973 + tc_ac.stop;
  1974 + setverdict(fail, __SCOPE__ & ": Wrong response status code");
1976 1975 }
1977   - }
1978   -
1979   - f_checkCseSimuStatus();
1980   -
1981   - //Check to see if the resource is present or not
1982   - if (f_cse_isResourcePresent(v_resourceIndex)){
1983   - setverdict(pass, __SCOPE__ & ":INFO: Resource created");
1984   - } else {
1985   - setverdict(fail, __SCOPE__ & ":ERROR: Resource not created");
  1976 + [] mccPort.receive(mw_response(mw_responsePrimitiveKO)) -> value vc_response {
  1977 + tc_ac.stop;
  1978 + setverdict(fail, __SCOPE__ & ": Error while creating resource type " & int2str(enum2int(p_resourceType)));
1986 1979 }
1987   -
1988   - // Postamble
1989   - f_cse_postamble_deleteResourcesCSE();
1990   -
1991   - // Tear down
1992   - f_cf02DownCseSimuMaster();
1993   -
1994   - return vc_response.primitive.responsePrimitive;
1995   -
1996   - }//end f_CSE_DMR_CRE_001_cseSimu
  1980 + [] tc_ac.timeout {
  1981 + setverdict(fail, __SCOPE__ & ": No answer while creating resource type " & int2str(enum2int(p_resourceType)));
  1982 + }
  1983 + }
  1984 +
  1985 + f_checkCseSimuStatus();
  1986 +
  1987 + //Check to see if the resource is present or not
  1988 + if (f_cse_isResourcePresent(v_resourceIndex)){
  1989 + setverdict(pass, __SCOPE__ & ":INFO: Resource created");
  1990 + } else {
  1991 + setverdict(fail, __SCOPE__ & ":ERROR: Resource not created");
  1992 + }
  1993 +
  1994 + // Postamble
  1995 + f_cse_postamble_deleteResourcesCSE();
  1996 +
  1997 + // Tear down
  1998 + f_cf02DownCseSimuMaster();
  1999 +
  2000 + }//end f_CSE_DMR_CRE_001_cseSimu
1997 2001  
1998 2002 function f_CSE_DMR_CRE_002(ResourceType p_resourceType, template RequestPrimitive p_requestPrimitive) runs on AeSimu return ResponsePrimitive{//system CseSystem { MRO system keyword not supported on functions in Titan
1999 2003  
... ... @@ -2822,58 +2826,68 @@ module OneM2M_PermutationFunctions {
2822 2826  
2823 2827 }//end f_CSE_DMR_CRE_017
2824 2828  
2825   - function f_CSE_DMR_CRE_019(ResourceType p_resourceType, template RequestPrimitive p_createRequestAnnc) runs on CseSimu {
  2829 + function f_CSE_DMR_CRE_019(ResourceType p_resourceType, template RequestPrimitive p_requestPrimitive) runs on CseSimu{
  2830 +
2826 2831 // Local variables
2827   - var MsgIn v_request;
  2832 + var MsgIn v_response;
  2833 + var RequestPrimitive v_request;
2828 2834 var integer v_parentIndex := -1;
2829   - var integer v_aeIndex := -1;
2830   - var integer v_resourceIndex;
  2835 + var integer v_resourceIndex := -1;
2831 2836 var integer v_aEAnncIndex := -1;
2832   - var RequestPrimitive v_createAEAnnc;
2833   - var RequestPrimitive v_aeAnnc;
2834   - var ResponsePrimitive v_responsePrimitive;
2835 2837  
2836 2838 // Test control
2837   -
  2839 +
2838 2840 // Test component configuration
2839 2841 f_cf04Up();
2840   -
  2842 +
2841 2843 // Test adapter configuration
2842   - // Register the CSE
2843   - f_cse_registerRemoteCse(m_createRemoteCSEBase);
  2844 +
  2845 + // Preamble
  2846 + vc_remoteCseIndex := f_cse_registerRemoteCse(m_createRemoteCSEBase);
  2847 +
  2848 + v_aEAnncIndex := f_cse_createResource_cseSimu(int10002, m_createAEAnnc(omit, omit, omit, PX_CSE1_ID), vc_remoteCseIndex); //AEAnnnc under RemoteCSE
2844 2849  
2845 2850 // Test Body
2846   - v_createAEAnnc := m_createAEAnnc(omit, omit, omit, PX_CSE1_ID);
2847   - v_aeAnnc := f_getCreateRequestPrimitive(int10002, v_createAEAnnc, -1);
2848   - mccPort.send(m_request(v_aeAnnc));
2849   -
2850   - // Test Body
  2851 +
  2852 + v_request := f_getCreateRequestPrimitive(p_resourceType, p_requestPrimitive, v_aEAnncIndex);
  2853 +
  2854 + mccPort.send(f_getMsgOutPrimitive(m_request(v_request)));
2851 2855 tc_ac.start;
2852 2856 alt {
2853   - [] mccPortIn.receive(mw_request(p_createRequestAnnc)) -> value v_request {
  2857 + [] mccPort.receive(mw_response(mw_responsePrimitive(int2001))) -> value vc_response {
2854 2858 tc_ac.stop;
2855   - setverdict(pass, __SCOPE__ & ":INFO: CREATE REQUEST received");
2856   -
2857   - if(match(v_request.primitive.requestPrimitive.to_, f_getLocalResourceAddress(v_aEAnncIndex, e_hierarchical, e_spRelative)) or
2858   - match(v_request.primitive.requestPrimitive.to_, f_getLocalResourceAddress(v_aEAnncIndex, e_nonHierarchical, e_spRelative))) {
2859   - setverdict(pass, __SCOPE__ & ":matching ANNC_PARENT_RESOURCE_ADDRESS");
2860   - } else {
2861   - setverdict(fail, __SCOPE__ & ":mis-matching ANNC_PARENT_RESOURCE_ADDRESS");
  2859 + setverdict(pass, __SCOPE__ & ": Resource type " & int2str(enum2int(p_resourceType)) & " created successfully");
  2860 + f_checkAttributesToBeSaved(p_resourceType, v_request, vc_response.primitive.responsePrimitive);
  2861 + v_resourceIndex := f_setResource(vc_response.primitive.responsePrimitive.primitiveContent, p_resourceType, v_aEAnncIndex);
  2862 + }
  2863 + [] mccPort.receive(mw_response(mw_responsePrimitiveOK)) -> value vc_response {
  2864 + tc_ac.stop;
  2865 + setverdict(fail, __SCOPE__ & ": Wrong response status code");
2862 2866 }
2863   -
  2867 + [] mccPort.receive(mw_response(mw_responsePrimitiveKO)) -> value vc_response {
  2868 + tc_ac.stop;
  2869 + setverdict(fail, __SCOPE__ & ": Error while creating resource type " & int2str(enum2int(p_resourceType)));
2864 2870 }
2865 2871 [] tc_ac.timeout {
2866   - setverdict(fail, __SCOPE__ & ":ERROR: No CREATE REQUEST received");
  2872 + setverdict(fail, __SCOPE__ & ": No answer while creating resource type " & int2str(enum2int(p_resourceType)));
2867 2873 }
  2874 + }
  2875 +
  2876 + f_checkCseSimuStatus();
  2877 +
  2878 + //Check to see if the resource is present or not
  2879 + if (f_cse_isResourcePresent(v_resourceIndex)){
  2880 + setverdict(pass, __SCOPE__ & ":INFO: Resource created");
  2881 + } else {
  2882 + setverdict(fail, __SCOPE__ & ":ERROR: Resource not created");
2868 2883 }
2869   -
2870   -
  2884 +
2871 2885 // Postamble
2872 2886 f_cse_postamble_deleteResourcesCSE();
2873   -
  2887 +
2874 2888 // Tear down
2875 2889 f_cf04Down();
2876   -
  2890 +
2877 2891 }//end f_CSE_DMR_CRE_019
2878 2892  
2879 2893 function f_CSE_DMR_CRE_020(ResourceType p_resourceType, template RequestPrimitive p_requestPrimitive, template (present) RequestPrimitive p_requestAnnc) runs on AeSimu {
... ...
... ... @@ -503,20 +503,17 @@ module OneM2M_Testcases_CSE_Release_2 {
503 503 }
504 504  
505 505 testcase TC_CSE_DMR_CRE_001_SUB_AEA() runs on Tester system CseSystem {
506   - // Local variables
  506 + //Local variables
507 507 var template RequestPrimitive v_createRequest := m_createSubscriptionBase;
508 508 var ResponsePrimitive v_responsePrimitive;
509 509 var RequestPrimitive v_createAEAnnc := m_createAEAnnc(omit, omit, omit, PX_CSE1_ID);
510   - var AeSimu v_ae1 := AeSimu.create("AE1") alive;
511   -
512   -
513   - v_createRequest.primitiveContent.subscription.resourceName := omit;
514   - v_ae1.start(f_CSE_DMR_CRE_001(int23, v_createRequest, v_createAEAnnc));//Subscription
515   - v_ae1.done;
  510 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
516 511  
517   -
  512 + v_createRequest.primitiveContent.timeSeries.resourceName := omit;
  513 + v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int23, v_createRequest, int10002, v_createAEAnnc));//Subscription
  514 + v_cse1.done;
518 515  
519   - if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
  516 + if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
520 517 if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
521 518 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
522 519 }
... ... @@ -524,22 +521,22 @@ module OneM2M_Testcases_CSE_Release_2 {
524 521 }
525 522  
526 523 testcase TC_CSE_DMR_CRE_001_CNT_AEA() runs on Tester system CseSystem {
527   - // Local variables
  524 + //Local variables
528 525 var template RequestPrimitive v_createRequest := m_createContainerBase;
529 526 var ResponsePrimitive v_responsePrimitive;
530 527 var RequestPrimitive v_createAEAnnc := m_createAEAnnc(omit, omit, omit, PX_CSE1_ID);
531   - var AeSimu v_ae1 := AeSimu.create("AE1") alive;
532   -
533   -
534   - v_createRequest.primitiveContent.subscription.resourceName := omit;
535   - v_ae1.start(f_CSE_DMR_CRE_001(int3, v_createRequest, v_createAEAnnc));//Container
536   - v_ae1.done;
  528 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
537 529  
538   - if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
  530 + v_createRequest.primitiveContent.container.resourceName := omit;
  531 + v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int3, v_createRequest, int10002, v_createAEAnnc));//Container
  532 + v_cse1.done;
  533 +
  534 + if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
539 535 if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
540 536 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
541 537 }
542 538 }
  539 +
543 540 }
544 541  
545 542 testcase TC_CSE_DMR_CRE_001_GRP_AEA() runs on Tester system CseSystem {
... ... @@ -547,14 +544,14 @@ module OneM2M_Testcases_CSE_Release_2 {
547 544 var template RequestPrimitive v_createRequest := m_createGroupBase;
548 545 var ResponsePrimitive v_responsePrimitive;
549 546 var RequestPrimitive v_createAEAnnc := m_createAEAnnc(omit, omit, omit, PX_CSE1_ID);
550   - var AeSimu v_ae1 := AeSimu.create("AE1") alive;
  547 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
551 548  
552   - v_createRequest.primitiveContent.subscription.resourceName := omit;
553   - v_ae1.start(f_CSE_DMR_CRE_001(int9, v_createRequest, v_createAEAnnc));//Group
554   - v_ae1.done;
  549 + v_createRequest.primitiveContent.group_.resourceName := omit;
  550 + v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int9, v_createRequest, int10002, v_createAEAnnc));//Group
  551 + v_cse1.done;
555 552  
556   - if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
557   - if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
  553 + if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
  554 + if(not ispresent(v_responsePrimitive.primitiveContent.group_.resourceName)){
558 555 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
559 556 }
560 557 }
... ... @@ -565,14 +562,14 @@ module OneM2M_Testcases_CSE_Release_2 {
565 562 var template RequestPrimitive v_createRequest := m_createAcpBase;
566 563 var ResponsePrimitive v_responsePrimitive;
567 564 var RequestPrimitive v_createAEAnnc := m_createAEAnnc(omit, omit, omit, PX_CSE1_ID);
568   - var AeSimu v_ae1 := AeSimu.create("AE1") alive;
  565 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
569 566  
570   - v_createRequest.primitiveContent.subscription.resourceName := omit;
571   - v_ae1.start(f_CSE_DMR_CRE_001(int1, v_createRequest, v_createAEAnnc));//Access Control Policy
572   - v_ae1.done;
  567 + v_createRequest.primitiveContent.accessControlPolicy.resourceName := omit;
  568 + v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int1, v_createRequest, int10002, v_createAEAnnc));//Access Control Policy
  569 + v_cse1.done;
573 570  
574   - if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
575   - if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
  571 + if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
  572 + if(not ispresent(v_responsePrimitive.primitiveContent.accessControlPolicy.resourceName)){
576 573 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
577 574 }
578 575 }
... ... @@ -588,9 +585,7 @@ module OneM2M_Testcases_CSE_Release_2 {
588 585 v_createRequest.primitiveContent.node.resourceName := omit;
589 586  
590 587 v_ae1.start(f_CSE_DMR_CRE_001(int14, v_createRequest, -));//Node
591   - v_ae1.done;
592   -
593   -
  588 + v_ae1.done;
594 589  
595 590 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
596 591 if(not ispresent(v_responsePrimitive.primitiveContent.node.resourceName)){
... ... @@ -609,9 +604,7 @@ module OneM2M_Testcases_CSE_Release_2 {
609 604  
610 605 v_createRequest.primitiveContent.mgmtCmd.resourceName := omit;
611 606 v_ae1.start(f_CSE_DMR_CRE_001(int12, v_createRequest, -));//Management Command
612   - v_ae1.done;
613   -
614   -
  607 + v_ae1.done;
615 608  
616 609 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
617 610 if(not ispresent(v_responsePrimitive.primitiveContent.mgmtCmd.resourceName)){
... ... @@ -631,8 +624,6 @@ module OneM2M_Testcases_CSE_Release_2 {
631 624 v_createRequest.primitiveContent.locationPolicy.resourceName := omit;
632 625 v_ae1.start(f_CSE_DMR_CRE_001(int10, v_createRequest, -));//Location Policy
633 626 v_ae1.done;
634   -
635   -
636 627  
637 628 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
638 629 if(not ispresent(v_responsePrimitive.primitiveContent.locationPolicy.resourceName)){
... ... @@ -652,8 +643,6 @@ module OneM2M_Testcases_CSE_Release_2 {
652 643 v_createRequest.primitiveContent.statsConfig.resourceName := omit;
653 644 v_ae1.start(f_CSE_DMR_CRE_001(int22, v_createRequest, -));//Stats Config
654 645 v_ae1.done;
655   -
656   -
657 646  
658 647 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
659 648 if(not ispresent(v_responsePrimitive.primitiveContent.statsConfig.resourceName)){
... ... @@ -673,8 +662,6 @@ module OneM2M_Testcases_CSE_Release_2 {
673 662  
674 663 v_ae1.start(f_CSE_DMR_CRE_001(int21, v_createRequest, -));//Stats Collect
675 664 v_ae1.done;
676   -
677   -
678 665  
679 666 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
680 667 if(not ispresent(v_responsePrimitive.primitiveContent.statsCollect.resourceName)){
... ... @@ -694,8 +681,6 @@ module OneM2M_Testcases_CSE_Release_2 {
694 681 v_createRequest.primitiveContent.m2mServiceSubscriptionProfile.resourceName := omit;
695 682 v_ae1.start(f_CSE_DMR_CRE_001(int11, v_createRequest, -));//Subscription Profile
696 683 v_ae1.done;
697   -
698   -
699 684  
700 685 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
701 686 if(not ispresent(v_responsePrimitive.primitiveContent.m2mServiceSubscriptionProfile.resourceName)){
... ... @@ -715,8 +700,6 @@ module OneM2M_Testcases_CSE_Release_2 {
715 700 v_createRequest.primitiveContent.serviceSubscribedAppRule.resourceName := omit;
716 701 v_ae1.start(f_CSE_DMR_CRE_001(int19, v_createRequest, -));//Service Subscribed App
717 702 v_ae1.done;
718   -
719   -
720 703  
721 704 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_ae1);
722 705 if(not ispresent(v_responsePrimitive.primitiveContent.serviceSubscribedAppRule.resourceName)){
... ... @@ -770,7 +753,7 @@ module OneM2M_Testcases_CSE_Release_2 {
770 753 var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
771 754  
772 755 v_createRequest.primitiveContent.timeSeries.resourceName := omit;
773   - v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int29, v_createRequest));//TimeSeries
  756 + v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int29, v_createRequest, -, -));//TimeSeries
774 757 v_cse1.done;
775 758  
776 759 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
... ... @@ -780,6 +763,24 @@ module OneM2M_Testcases_CSE_Release_2 {
780 763 }
781 764 }
782 765  
  766 + testcase TC_CSE_DMR_CRE_001_TS_AEA() runs on Tester system CseSystem {
  767 + // Local variables
  768 + var template RequestPrimitive v_createRequest := m_createTimeSeriesBase;
  769 + var ResponsePrimitive v_responsePrimitive;
  770 + var RequestPrimitive v_createAEAnnc := m_createAEAnnc(omit, omit, omit, PX_CSE1_ID);
  771 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
  772 +
  773 + v_createRequest.primitiveContent.timeSeries.resourceName := omit;
  774 + v_cse1.start(f_CSE_DMR_CRE_001_cseSimu(int29, v_createRequest, int10002, v_createAEAnnc));//TimeSeries
  775 + v_cse1.done;
  776 +
  777 + if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
  778 + if(not ispresent(v_responsePrimitive.primitiveContent.timeSeries.resourceName)){
  779 + setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
  780 + }
  781 + }
  782 + }
  783 +
783 784 testcase TC_CSE_DMR_CRE_001_TSI_TS() runs on Tester system CseSystem {
784 785 // Local variables
785 786 var template RequestPrimitive v_createRequest := m_createTimeSeriesInstanceBase;
... ... @@ -1893,16 +1894,16 @@ module OneM2M_Testcases_CSE_Release_2 {
1893 1894  
1894 1895 testcase TC_CSE_DMR_CRE_019_CNTA_AEA() runs on Tester system CseSystem {
1895 1896 // Local variables
1896   - var template RequestPrimitive v_createRequest := m_createContainerBase;
  1897 + var template RequestPrimitive v_createRequest := m_createContainerAnncBase;
1897 1898 var ResponsePrimitive v_responsePrimitive;
1898 1899 var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
1899 1900  
1900   - v_createRequest.primitiveContent.subscription.resourceName := omit;
1901   - v_cse1.start(f_CSE_DMR_CRE_019(int3, v_createRequest));//Container
  1901 + v_createRequest.primitiveContent.containerAnnc.resourceName := omit;
  1902 + v_cse1.start(f_CSE_DMR_CRE_019(int10003, v_createRequest));//ContainerAnnc
1902 1903 v_cse1.done;
1903 1904  
1904 1905 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
1905   - if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
  1906 + if(not ispresent(v_responsePrimitive.primitiveContent.containerAnnc.resourceName)){
1906 1907 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
1907 1908 }
1908 1909 }
... ... @@ -1910,16 +1911,16 @@ module OneM2M_Testcases_CSE_Release_2 {
1910 1911  
1911 1912 testcase TC_CSE_DMR_CRE_019_GRPA_AEA() runs on Tester system CseSystem {
1912 1913 // Local variables
1913   - var template RequestPrimitive v_createRequest := m_createGroupBase;
  1914 + var template RequestPrimitive v_createRequest := m_createGroupAnncBase;
1914 1915 var ResponsePrimitive v_responsePrimitive;
1915 1916 var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
1916 1917  
1917   - v_createRequest.primitiveContent.subscription.resourceName := omit;
1918   - v_cse1.start(f_CSE_DMR_CRE_019(int9, v_createRequest));//Group
  1918 + v_createRequest.primitiveContent.groupAnnc.resourceName := omit;
  1919 + v_cse1.start(f_CSE_DMR_CRE_019(int10009, v_createRequest));//GroupAnnc
1919 1920 v_cse1.done;
1920 1921  
1921 1922 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
1922   - if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
  1923 + if(not ispresent(v_responsePrimitive.primitiveContent.groupAnnc.resourceName)){
1923 1924 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
1924 1925 }
1925 1926 }
... ... @@ -1927,16 +1928,33 @@ module OneM2M_Testcases_CSE_Release_2 {
1927 1928  
1928 1929 testcase TC_CSE_DMR_CRE_019_ACPA_AEA() runs on Tester system CseSystem {
1929 1930 // Local variables
1930   - var template RequestPrimitive v_createRequest := m_createAcpBase;
  1931 + var template RequestPrimitive v_createRequest := m_createAcpAnncBase;
1931 1932 var ResponsePrimitive v_responsePrimitive;
1932 1933 var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
1933 1934  
1934   - v_createRequest.primitiveContent.subscription.resourceName := omit;
1935   - v_cse1.start(f_CSE_DMR_CRE_019(int1, v_createRequest));//Access Control Policy
  1935 + v_createRequest.primitiveContent.accessControlPolicyAnnc.resourceName := omit;
  1936 + v_cse1.start(f_CSE_DMR_CRE_019(int10001, v_createRequest));//AccessControlPolicyAnnc
1936 1937 v_cse1.done;
1937 1938  
1938 1939 if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
1939   - if(not ispresent(v_responsePrimitive.primitiveContent.subscription.resourceName)){
  1940 + if(not ispresent(v_responsePrimitive.primitiveContent.accessControlPolicyAnnc.resourceName)){
  1941 + setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
  1942 + }
  1943 + }
  1944 + }
  1945 +
  1946 + testcase TC_CSE_DMR_CRE_019_TSA_AEA() runs on Tester system CseSystem {
  1947 + // Local variables
  1948 + var template RequestPrimitive v_createRequest := m_createTimeSeriesAnncBase;
  1949 + var ResponsePrimitive v_responsePrimitive;
  1950 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
  1951 +
  1952 + v_createRequest.primitiveContent.timeSeriesAnnc.resourceName := omit;
  1953 + v_cse1.start(f_CSE_DMR_CRE_019(int10029, v_createRequest));//TimeSeriesAnnc
  1954 + v_cse1.done;
  1955 +
  1956 + if(getverdict == pass){ v_responsePrimitive := f_getResponsePrimitive(v_cse1);
  1957 + if(not ispresent(v_responsePrimitive.primitiveContent.timeSeriesAnnc.resourceName)){
1940 1958 setverdict(fail, __SCOPE__, ": Error, resourceName attribute not provided");
1941 1959 }
1942 1960 }
... ... @@ -6929,6 +6947,32 @@ module OneM2M_Testcases_CSE_Release_2 {
6929 6947 v_cse1.start(f_CSE_DMR_UPD_017(int18, v_createRequest, v_createRequestAnnc, v_updateRequest));//Schedule
6930 6948 v_cse1.done;
6931 6949 }
  6950 +
  6951 + testcase TC_CSE_DMR_UPD_017_TS() runs on Tester system CseSystem {
  6952 + // Local variables
  6953 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
  6954 + var template RequestPrimitive v_createRequest := m_createTimeSeriesBase;
  6955 + var template RequestPrimitive v_createRequestAnnc := mw_createTimeSeriesAnncBase;
  6956 + var template RequestPrimitive v_updateRequest := m_updateTimeSeriesBase;
  6957 +
  6958 + v_updateRequest.primitiveContent.timeSeries.announceTo := {PX_CSE1_ID};
  6959 +
  6960 + v_cse1.start(f_CSE_DMR_UPD_017(int29, v_createRequest, v_createRequestAnnc, v_updateRequest));//TimeSeries
  6961 + v_cse1.done;
  6962 + }
  6963 +
  6964 + testcase TC_CSE_DMR_UPD_017_TSI() runs on Tester system CseSystem {
  6965 + // Local variables
  6966 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
  6967 + var template RequestPrimitive v_createRequest := m_createTimeSeriesInstanceBase;
  6968 + var template RequestPrimitive v_createRequestAnnc := mw_createTimeSeriesInstanceAnncBase;
  6969 + var template RequestPrimitive v_updateRequest := m_updateTimeSeriesInstanceBase;
  6970 +
  6971 + v_updateRequest.primitiveContent.timeSeriesInstance.announceTo := {PX_CSE1_ID};
  6972 +
  6973 + v_cse1.start(f_CSE_DMR_UPD_017(int29, v_createRequest, v_createRequestAnnc, v_updateRequest));//TimeSeriesInstance
  6974 + v_cse1.done;
  6975 + }
6932 6976  
6933 6977 } //end group g_CSE_DMR_UPD_017
6934 6978  
... ... @@ -6996,6 +7040,28 @@ module OneM2M_Testcases_CSE_Release_2 {
6996 7040 v_cse1.done;
6997 7041 }
6998 7042  
  7043 + testcase TC_CSE_DMR_UPD_018_TS_MBS() runs on Tester system CseSystem {
  7044 + // Local variables
  7045 + var CseSimu v_cse1 := CseSimu.create("CSE1") alive;
  7046 + var template RequestPrimitive v_createRequest := m_createTimeSeriesBase;
  7047 + var template RequestPrimitive v_createRequestAnnc := mw_createTimeSeriesAnncBase;
  7048 + var template RequestPrimitive v_updateRequest := m_updateTimeSeriesBase;
  7049 + var template RequestPrimitive v_updateRequestAnnc := mw_updateTimeSeriesAnnc;
  7050 + var XSD.NonNegativeInteger v_maxByteSize := 512;
  7051 +
  7052 + v_createRequest.primitiveContent.timeSeries.announceTo := {PX_CSE1_ID};
  7053 + v_createRequest.primitiveContent.timeSeries.maxByteSize := v_maxByteSize;
  7054 +
  7055 + v_createRequestAnnc.primitiveContent.timeSeriesAnnc.maxByteSize := v_maxByteSize;
  7056 +
  7057 + v_updateRequest.primitiveContent.timeSeries.announcedAttribute := {"maxByteSize"};
  7058 +
  7059 + v_updateRequestAnnc.primitiveContent.timeSeriesAnnc.maxByteSize := v_maxByteSize;
  7060 +
  7061 + v_cse1.start(f_CSE_DMR_UPD_018(int29, v_createRequest, v_createRequestAnnc, v_updateRequest, v_updateRequestAnnc));//TimeSeries
  7062 + v_cse1.done;
  7063 + }
  7064 +
6999 7065 } //end group g_CSE_DMR_UPD_018
7000 7066 }//end group Update
7001 7067  
... ...