To add a collaborator to this project you will need to use the Relish gem to add the collaborator via a terminal command. Soon you'll be able to also add collaborators here!
More about adding a collaboratorGenealogy - Parts
A Robot
Should be able to interact with Parts using XYZ API
- Scenarios
-
- Record a part assembly
- Record a part assembly
- Record a part assembly
- Request to incorrect API namespace
- Request to incorrect API service name
- User not authorized for API calls
- Non-GET request to Find-Parts service
- Find parts with no search criteria specified
- Find parts by specifying a non-existing product family
- Find parts by specifying a product family
- Find parts by specifying a non-existing part number
- Find parts by specifying a part number
- Find parts by specifying a part number with a wildcard
- Find parts by specifying a comma-delimited part number
- Find parts by specifying a non-existing version
- Find parts by specifying a part number and version
- Find parts by specifying a non-existing revision
- Find parts by specifying a part number and revision
- Find parts by specifying a serial number that doesn't exist
- Find parts by specifying a serial number
- Find parts by specifying a serial number with a wildcard
- Find parts by specifying a comma-delimited serial number
- Find parts by specifying a serial number and a lot number
- Find parts by specifying a lot number
- Find parts by specifying a lot number with a wildcard
- Find parts by specifying a comma-delimited lot number
- Find parts by specifying an APS attribute that doesn't exist
- Find parts by specifying a string APS attribute
- Find parts by specifying an integer APS attribute
- Find parts by specifying a double APS attribute
- Find parts by specifying a boolean APS attribute set to F
- Find parts by specifying a boolean APS attribute set to T
- Find parts by specifying a timestamp APS attribute
- Find parts by specifying multiple APS attributes
- Find parts by specifying a Part attribute that doesn't exist
- Find parts by specifying a common Part attribute
- Find parts by specifying an integer Part attribute
- Find parts by specifying a double Part attribute
- Find parts by specifying a boolean Part attribute
- Find parts by specifying a timestamp Part attribute
- Find parts by specifying multiple Part attributes
- Find parts by specifying a from date greater than the to date
- Find parts by specifying a from date
- Find parts by specifying a to date
- Find parts by specifying a from and to date
- Record a part assembly
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "assemble"
- And
- uses HTTP method "POST"
- And
- uses XML-file "find-parts.Assemble.Record1.xml"
- Then
- Robot should see response status "success"
- Record a part assembly
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "assemble"
- And
- uses HTTP method "POST"
- And
- uses XML-file "find-parts.Assemble.Record2.xml"
- Then
- Robot should see response status "success"
- Record a part assembly
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "assemble"
- And
- uses HTTP method "POST"
- And
- uses XML-file "find-parts.Assemble.Record3.xml"
- Then
- Robot should see response status "success"
- Request to incorrect API namespace
-
- Given
- XYZ API domain
- And
- namespace "/genealogy/incorrect_namespace/" and authorized user
- When
- Robot requests service name "find-parts"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "failure"
- And
- Robot should see error type "NoSuchNamespace"
- Request to incorrect API service name
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "incorrect_service"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "failure"
- And
- Robot should see error type "NoSuchService"
- User not authorized for API calls
-
- Given
- XYZ API domain and Parts namespace
- When
- Robot requests service name "find-parts"
- And
- uses user "[email protected]"
- And
- uses password "qatest"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "failure"
- And
- Robot should see error type "AuthorizationFailure"
- Non-GET request to Find-Parts service
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- uses HTTP method "POST"
- Then
- Robot should see response status "failure"
- And
- Robot should see error type "GetRequired"
- Find parts with no search criteria specified
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- Find parts by specifying a non-existing product family
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "family" parameter "blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a product family
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "family" parameter "QC PRODUCT FAMILY 3"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c3-2
- Find parts by specifying a non-existing part number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "part-number" parameter "blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a part number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-number" parameter "QC1"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2
- Find parts by specifying a part number with a wildcard
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-number" parameter "QC1-C1*"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1-2 PREFIX_fp-c1a-2 PREFIX_fp-serial-100 PREFIX_fp-serial-101
- Find parts by specifying a comma-delimited part number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-number" parameter "QC1, QC1-C1B"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2 PREFIX_fp-serial-100 PREFIX_fp-serial-101
- Find parts by specifying a non-existing version
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "version" parameter "blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a part number and version
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-number" parameter "QC1"
- And
- with "version" parameter "V1"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2
- Find parts by specifying a non-existing revision
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "revision" parameter "blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a part number and revision
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-number" parameter "QC1"
- And
- with "revision" parameter "R1"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2
- Find parts by specifying a serial number that doesn't exist
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "blahblahblah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a serial number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp-c1a-2"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part.aps-attributes.aps-attribute" should contain following attributes:
name value QC1-2 String aps 2 QC1-1 boolean3 T QC1-1 boolean4 F QC1-2 Double 1.2 QC1-1 boolean1 T QC1-1 boolean2 F QC1-2 Timestamp 2011-01-11T03:30:02 QC1-1 integer3 3 QC1-1 integer4 4 QC1-1 integer1 1 QC1-1 integer2 2 QC1-2 Boolean T QC1-2 Integer 12 QC1-1 double1 1.1 QC1-1 double4 4.4 QC1-1 double2 2.5 QC1-1 double3 3.3 QC1-1 string1 string1 QC1-1 timestamp1 2010-01-11T03:22:01 QC1-1 timestamp2 2010-01-11T03:22:02 QC1-1 string4 a4 QC1-1 timestamp3 2010-01-11T03:22:03 QC1-1 string3 123 QC1-1 string2 [email protected] QC1-1 timestamp4 2010-01-11T03:22:04
- Find parts by specifying a serial number with a wildcard
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp-c*"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1-2 PREFIX_fp-c1a-2 PREFIX_fp-c2-2 PREFIX_fp-c3-2
- Find parts by specifying a comma-delimited serial number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp-qc1-2,PREFIX_blah, PREFIX_fp-c1-2"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2 PREFIX_fp-c1-2
- Find parts by specifying a serial number and a lot number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp-qc1*"
- And
- with "lot-number" parameter "blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "failure"
- And
- Robot should see error type "InvalidParameter"
- And
- Robot should see msg "Cannot search for both serialNumber and lotNumber at the same time!"
- Find parts by specifying a lot number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "lot-number" parameter "PREFIX_fp-lot2b"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part.part-attributes.part-attribute" should contain following attributes:
name value Lot-Based Serial Number serial2 C1aa integer 3
- Find parts by specifying a lot number with a wildcard
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "lot-number" parameter "PREFIX_fp*"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
lot-number PREFIX_fp-lot1b PREFIX_fp-lot2b
- Find parts by specifying a comma-delimited lot number
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "lot-number" parameter "PREFIX_fp-lot1b,PREFIX_fp-lot2b,PREFIX_fp-blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
lot-number PREFIX_fp-lot1b PREFIX_fp-lot2b
- Find parts by specifying an APS attribute that doesn't exist
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "aps-attributes" parameter "blah:blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a string APS attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 string4:a4"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying an integer APS attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 integer4:4"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying a double APS attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 double4:4.4"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying a boolean APS attribute set to F
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 boolean4:F"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying a boolean APS attribute set to T
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 boolean3:T"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying a timestamp APS attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 timestamp4:2010-01-11T02\:22\:04-08\:00"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying multiple APS attributes
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "aps-attributes" parameter "QC1-1 string4:a4,QC1-1 double1:1.1"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying a Part attribute that doesn't exist
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "part-attributes" parameter "blah:blah"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
- returned node "list" should be empty
- Find parts by specifying a common Part attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-attributes" parameter "Common PartAttribute:a"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2
- Find parts by specifying an integer Part attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-attributes" parameter "QC1 integer:1"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2
- Find parts by specifying a double Part attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-attributes" parameter "QC1 double:1.1"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2
- Find parts by specifying a boolean Part attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-attributes" parameter "C3 boolean:F"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c3-2
- Find parts by specifying a timestamp Part attribute
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "part-attributes" parameter "C3 timestamp:2010-01-12T11\:22\:02Z"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c3-2
- Find parts by specifying multiple Part attributes
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "Part-attributes" parameter "C3 string 2:string 2:C3 double:3.123"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c3-2
- Find parts by specifying a from date greater than the to date
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "from" parameter "2011-01-12T11:30:54Z"
- And
- with "to" parameter "2011-01-11T11:33:39Z"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "failure"
- And
- Robot should see error type "InvalidParameter"
- And
- Robot should see msg "TO date cannot be before FROM date!"
- Find parts by specifying a from date
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "from" parameter "2011-01-11T11:30:55-08:00"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-qc1-2 PREFIX_fp-c1-2 PREFIX_fp-c2-2 PREFIX_fp-c3-2
- Find parts by specifying a to date
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "to" parameter "2011-01-11T11:30:54-08:00"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1a-2
- Find parts by specifying a from and to date
-
- Given
- XYZ API domain, Parts namespace and username "[email protected]" with password "aut"
- When
- Robot requests service name "find-parts"
- And
- with "serial-number" parameter "PREFIX_fp*"
- And
- with "from" parameter "2011-01-11T11:30:54-08:00"
- And
- with "to" parameter "2011-01-11T11:33:39-08:00"
- And
- uses HTTP method "GET"
- Then
- Robot should see response status "success"
- And
-
returned node "list.part" should contain following attributes:
serial-number PREFIX_fp-c1-2 PREFIX_fp-c1a-2 PREFIX_fp-serial-100 PREFIX_fp-serial-101
Last published almost 7 years ago by dabravolski.