Skip to content

Commit

Permalink
chore(test):[eclipse-tractusx#529] Corrections SingleLevelBomAsBuilt
Browse files Browse the repository at this point in the history
  • Loading branch information
dsmf committed Jun 17, 2024
1 parent f03c0a2 commit 24c8e30
Show file tree
Hide file tree
Showing 6 changed files with 295 additions and 39 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@ Test data:


Structure of test data:
- SingleLevelBomAsBuilt 3.0.0, BPNL00E2EASPCPT1, urn:uuid:a0589022-a790-4560-aad1-5e8f7939fe92
- SerialPart 1.0.1, urn:uuid:6d759367-12fe-4f04-9a8c-5c9432135e41
- SingleLevelBomAsBuilt 3.1.0, BPNL00E2EASPCP11, urn:uuid:4b1b50f7-686d-4c3a-b81a-5f6fc6ae5c42
- futureAddedField
- SerialPart 2.0.0, urn:uuid:ff5d998c-aadb-4189-9cf0-9ab5c42c94fe
- SerialPart 3.0.0, urn:uuid:976dbbce-5a5f-4118-a2bd-5fbca2aeabb5
- SingleLevelBomAsBuilt 2.0.0, BPNL00E2EASPCP12, urn:uuid:62aa5c23-780c-4036-8416-97922e3f71a4
- SerialPart 2.0.0, urn:uuid:024f941b-594f-43ce-a42e-d17d1c302685
- SingleLevelBomAsBuilt 2.0.0, BPNL00E2EASPC121, urn:uuid:2507bfdd-22df-43c2-99ab-9c2cf9ac0251
- SerialPart 2.0.0, urn:uuid:34c790e9-afa3-475c-a41b-3a86a9969f61
- OK: SingleLevelBomAsBuilt 3.0.0, BPNL00000007QG00, urn:uuid:bec0a457-4d6b-4c1c-88f7-125d04f04d68
- OK: SerialPart 1.0.1, urn:uuid:25bba830-bcd8-4123-be72-e5507b2ae827
- ??: SingleLevelBomAsBuilt 3.1.0, BPNL00000007RI31, urn:uuid:589d7f27-d200-4009-b24c-27b0f4b81528 --> Tombstone: Unable to find any of the requested shells. Why?
- ??: futureAddedField
- ??: SerialPart 2.0.0, urn:uuid:1c151801-0d9d-4fc6-af91-0ddcfe8d86e3
- ??: SerialPart 3.0.0, urn:uuid:5bd8e513-b69d-4b08-a387-24d787ac5545
- SingleLevelBomAsBuilt 2.0.0, BPNL00000003CSAP, urn:uuid:6e709d64-bdc7-49f4-a87d-4e1f7e2c3b7c
- OK: SerialPart 2.0.0, urn:uuid:162cb1f1-c619-47db-ab7f-44a111a762fc
- OK: SingleLevelBomAsBuilt 2.0.0, BPNL00000007RNYV, urn:uuid:d23f278b-2d8b-4f11-af76-2a9a7bb91cfc
- OK: SerialPart 2.0.0, urn:uuid:bc8b6912-4be3-4b4c-a28a-919ba405a5c2

Test:

Expand All @@ -32,7 +32,6 @@ Test:
- [529-single-level-bom-as-built-expected-submodels.json](../../../irs-cucumber-tests/src/test/resources/expected-files/529-single-level-bom-as-built-expected-submodels.json)



## SingleLevelBomAsPlanned

Test data:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,61 @@
{
"_todo": "todo #529 execute test, check if result is ok, add relationships here",
"relationships": [
{
"catenaXId": "urn:uuid:bec0a457-4d6b-4c1c-88f7-125d04f04d68",
"linkedItem": {
"quantity": {
"quantityNumber": 20.0,
"measurementUnit": {
"datatypeURI": null,
"lexicalValue": "unit:piece"
}
},
"lifecycleContext": "asBuilt",
"assembledOn": "2022-02-03T14:48:54.709Z",
"lastModifiedOn": "2022-02-03T14:48:54.709Z",
"childCatenaXId": "urn:uuid:6e709d64-bdc7-49f4-a87d-4e1f7e2c3b7c",
"hasAlternatives": false
},
"aspectType": "SingleLevelBomAsBuilt",
"bpn": "BPNL00000003CSAP"
},
{
"catenaXId": "urn:uuid:bec0a457-4d6b-4c1c-88f7-125d04f04d68",
"linkedItem": {
"quantity": {
"quantityNumber": 20.0,
"measurementUnit": {
"datatypeURI": null,
"lexicalValue": "unit:piece"
}
},
"lifecycleContext": "asBuilt",
"assembledOn": "2022-02-03T14:48:54.709Z",
"lastModifiedOn": "2022-02-03T14:48:54.709Z",
"childCatenaXId": "urn:uuid:589d7f27-d200-4009-b24c-27b0f4b81528",
"hasAlternatives": false
},
"aspectType": "SingleLevelBomAsBuilt",
"bpn": "BPNL00000007RI31"
},
{
"catenaXId": "urn:uuid:6e709d64-bdc7-49f4-a87d-4e1f7e2c3b7c",
"linkedItem": {
"quantity": {
"quantityNumber": 2.5,
"measurementUnit": {
"datatypeURI": null,
"lexicalValue": "unit:litre"
}
},
"lifecycleContext": "asBuilt",
"assembledOn": "2022-02-03T14:48:54.709Z",
"lastModifiedOn": "2022-02-03T14:48:54.709Z",
"childCatenaXId": "urn:uuid:d23f278b-2d8b-4f11-af76-2a9a7bb91cfc",
"hasAlternatives": false
},
"aspectType": "SingleLevelBomAsBuilt",
"bpn": "BPNL00000007RNYV"
}
]
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,93 @@
{
"_todo": "todo #529 execute test, check if result is ok, add submodels here",
"submodels": [
]
"submodels": [
{
"identification": "urn:uuid:54d3e5a3-4f80-4386-ae43-3a5080544f29",
"aspectType": "urn:samm:io.catenax.serial_part:1.0.1#SerialPart",
"contractAgreementId": null,
"payload": {
"catenaXId": "urn:uuid:25bba830-bcd8-4123-be72-e5507b2ae827",
"localIdentifiers": [
{
"value": "SN12345678",
"key": "partInstanceID"
}
],
"manufacturingInformation": {
"date": "2024-02-04T14:48:54",
"country": "HUR"
},
"partTypeInformation": {
"manufacturerPartId": "456-7.890-1234-A",
"customerPartId": "PRT-12345",
"classification": "product",
"nameAtManufacturer": "Test part 1",
"nameAtCustomer": "Test part 1 customer"
}
}
},
{
"identification": "urn:uuid:4e94baab-6de5-4fe4-8dea-65030e5ef45e",
"aspectType": "urn:samm:io.catenax.serial_part:2.0.0#SerialPart",
"contractAgreementId": null,
"payload": {
"catenaXId": "urn:uuid:162cb1f1-c619-47db-ab7f-44a111a762fc",
"localIdentifiers": [
{
"value": "SN34567890",
"key": "partInstanceID"
}
],
"manufacturingInformation": {
"date": "2024-05-04T03:02:01",
"country": "HUR"
},
"sites": [
{
"catenaXsiteId": "BPNS4567890123ZZ",
"function": "production"
}
],
"partTypeInformation": {
"manufacturerPartId": "678-9.012-3456-C",
"customerPartId": "PRT-90123",
"classification": "product",
"nameAtManufacturer": "Test part 4",
"nameAtCustomer": "Test part 4 customer"
}
}
},
{
"identification": "urn:uuid:877f0599-a54a-4131-98e5-1334a15efb68",
"aspectType": "urn:samm:io.catenax.serial_part:2.0.0#SerialPart",
"contractAgreementId": null,
"payload": {
"catenaXId": "urn:uuid:bc8b6912-4be3-4b4c-a28a-919ba405a5c2",
"localIdentifiers": [
{
"value": "SN45678901",
"key": "partInstanceID"
}
],
"manufacturingInformation": {
"date": "2024-06-05T04:03:02",
"country": "HUR"
},
"sites": [
{
"catenaXsiteId": "BPNS5678901234ZZ",
"function": "production"
}
],
"partTypeInformation": {
"manufacturerPartId": "789-0.123-4567-D",
"customerPartId": "PRT-01234",
"classification": "product",
"nameAtManufacturer": "Test part 5",
"nameAtCustomer": "Test part 5 customer"
}
}
}
],
"bpns": [
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,20 @@ Feature: [TESTING] Integration E2E Tests for backward compatibility #529
######################################################################################################################

Scenario: SingleLevelBomAsBuilt
Given I register an IRS job for globalAssetId "urn:uuid:15cf842e-b20e-4219-a61b-99c01cec42ea" and BPN "BPNL00000003AVTH"
Given I register an IRS job for globalAssetId "urn:uuid:bec0a457-4d6b-4c1c-88f7-125d04f04d68" and BPN "BPNL00000007QG00"
And collectAspects "true"
And depth 10

# SingleLevelBomAsBuilt (see RelationshipAspect)
And direction "downward"
And bomLifecycle "asBuilt"

And aspects :
| urn:samm:io.catenax.single_level_bom_as_built:3.0.0#SingleLevelBomAsBuilt |
| urn:samm:io.catenax.serial_part:1.0.1#SerialPart |
| urn:samm:io.catenax.serial_part:2.0.0#SerialPart |
| urn:samm:io.catenax.serial_part:3.0.0#SerialPart |

When I get the job-id
Then I check, if the job has status "COMPLETED" within 20 minutes
And I check, if "relationships" are equal to "529-single-level-bom-as-built-expected-relationships.json"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@
},
"https://catenax.io/schema/TestDataContainer/1.0.0": [
{
"catenaXId": "urn:uuid:a0589022-a790-4560-aad1-5e8f7939fe92",
"bpnl": "BPNL00E2EASPCPT1",
"catenaXId": "urn:uuid:bec0a457-4d6b-4c1c-88f7-125d04f04d68",
"bpnl": "BPNL00000007QG00",
"urn:samm:io.catenax.single_level_bom_as_built:3.0.0#SingleLevelBomAsBuilt": [
{
"catenaXId": "urn:uuid:a0589022-a790-4560-aad1-5e8f7939fe92",
"catenaXId": "urn:uuid:bec0a457-4d6b-4c1c-88f7-125d04f04d68",
"childItems": [
{
"catenaXId": "urn:uuid:4b1b50f7-686d-4c3a-b81a-5f6fc6ae5c42",
"businessPartner": "BPNL00E2EASPCP11",
"catenaXId": "urn:uuid:589d7f27-d200-4009-b24c-27b0f4b81528",
"businessPartner": "BPNL00000007RI31",
"hasAlternatives": false,
"quantity": {
"value": 20.0,
Expand All @@ -58,8 +58,8 @@
"lastModifiedOn": "2022-02-03T14:48:54.709Z"
},
{
"catenaXId": "urn:uuid:62aa5c23-780c-4036-8416-97922e3f71a4",
"businessPartner": "BPNL00E2EASPCP12",
"catenaXId": "urn:uuid:6e709d64-bdc7-49f4-a87d-4e1f7e2c3b7c",
"businessPartner": "BPNL00000003CSAP",
"validityPeriod": {
"validFrom": "2023-03-21T08:17:29.187+01:00",
"validTo": "2024-07-01T16:10:00.000+01:00"
Expand All @@ -76,7 +76,7 @@
],
"urn:samm:io.catenax.serial_part:1.0.1#SerialPart": [
{
"catenaXId": "urn:uuid:6d759367-12fe-4f04-9a8c-5c9432135e41",
"catenaXId": "urn:uuid:25bba830-bcd8-4123-be72-e5507b2ae827",
"localIdentifiers": [
{
"value": "SN12345678",
Expand All @@ -98,18 +98,18 @@
]
},
{
"catenaXId": "urn:uuid:4b1b50f7-686d-4c3a-b81a-5f6fc6ae5c42",
"bpnl": "BPNL00E2EASPCP11",
"catenaXId": "urn:uuid:589d7f27-d200-4009-b24c-27b0f4b81528",
"bpnl": "BPNL00000007RI31",
"urn:samm:io.catenax.single_level_bom_as_built:3.1.0#SingleLevelBomAsBuilt": [
{
"catenaXId": "urn:uuid:4b1b50f7-686d-4c3a-b81a-5f6fc6ae5c42",
"catenaXId": "urn:uuid:589d7f27-d200-4009-b24c-27b0f4b81528",
"childItems": [],
"futureAddedField": "test"
}
],
"urn:samm:io.catenax.serial_part:2.0.0#SerialPart": [
{
"catenaXId": "urn:uuid:ff5d998c-aadb-4189-9cf0-9ab5c42c94fe",
"catenaXId": "urn:uuid:1c151801-0d9d-4fc6-af91-0ddcfe8d86e3",
"localIdentifiers": [
{
"value": "SN23456789",
Expand Down Expand Up @@ -137,7 +137,7 @@
],
"urn:samm:io.catenax.serial_part:3.0.0#SerialPart": [
{
"catenaXId": "urn:uuid:976dbbce-5a5f-4118-a2bd-5fbca2aeabb5",
"catenaXId": "urn:uuid:5bd8e513-b69d-4b08-a387-24d787ac5545",
"localIdentifiers": [
{
"value": "SN56789012",
Expand Down Expand Up @@ -171,15 +171,15 @@
]
},
{
"catenaXId": "urn:uuid:62aa5c23-780c-4036-8416-97922e3f71a4",
"bpnl": "BPNL00E2EASPCP12",
"catenaXId": "urn:uuid:6e709d64-bdc7-49f4-a87d-4e1f7e2c3b7c",
"bpnl": "BPNL00000003CSAP",
"urn:samm:io.catenax.single_level_bom_as_built:2.0.0#SingleLevelBomAsBuilt": [
{
"catenaXId": "urn:uuid:62aa5c23-780c-4036-8416-97922e3f71a4",
"catenaXId": "urn:uuid:6e709d64-bdc7-49f4-a87d-4e1f7e2c3b7c",
"childItems": [
{
"catenaXId": "urn:uuid:2507bfdd-22df-43c2-99ab-9c2cf9ac0251",
"businessPartner": "BPNL00E2EASPC121",
"catenaXId": "urn:uuid:d23f278b-2d8b-4f11-af76-2a9a7bb91cfc",
"businessPartner": "BPNL00000007RNYV",
"quantity": {
"quantityNumber": 2.5,
"measurementUnit": "unit:litre"
Expand All @@ -193,7 +193,7 @@
],
"urn:samm:io.catenax.serial_part:2.0.0#SerialPart": [
{
"catenaXId": "urn:uuid:024f941b-594f-43ce-a42e-d17d1c302685",
"catenaXId": "urn:uuid:162cb1f1-c619-47db-ab7f-44a111a762fc",
"localIdentifiers": [
{
"value": "SN34567890",
Expand Down Expand Up @@ -221,17 +221,17 @@
]
},
{
"catenaXId": "urn:uuid:2507bfdd-22df-43c2-99ab-9c2cf9ac0251",
"bpnl": "BPNL00E2EASPC121",
"catenaXId": "urn:uuid:d23f278b-2d8b-4f11-af76-2a9a7bb91cfc",
"bpnl": "BPNL00000007RNYV",
"urn:samm:io.catenax.single_level_bom_as_built:2.0.0#SingleLevelBomAsBuilt": [
{
"catenaXId": "urn:uuid:2507bfdd-22df-43c2-99ab-9c2cf9ac0251",
"catenaXId": "urn:uuid:d23f278b-2d8b-4f11-af76-2a9a7bb91cfc",
"childItems": []
}
],
"urn:samm:io.catenax.serial_part:2.0.0#SerialPart": [
{
"catenaXId": "urn:uuid:34c790e9-afa3-475c-a41b-3a86a9969f61",
"catenaXId": "urn:uuid:bc8b6912-4be3-4b4c-a28a-919ba405a5c2",
"localIdentifiers": [
{
"value": "SN45678901",
Expand Down
Loading

0 comments on commit 24c8e30

Please sign in to comment.