Páginas filhas
  • Capacitação - Postman - Testes Serviços de Integrações - Exemplos

Versões comparadas

Chave

  • Esta linha foi adicionada.
  • Esta linha foi removida.
  • A formatação mudou.

...

Bloco de código
languagejs
titleResposta
collapsetrue
{
data: {
tasks: [
{
taskCostAssignments: [
{
itemNumber: "0001",
unitPrice: 10,
recno: 670,
itemInternalid: "T1||PRD44",
documentType: "NFE",
deductionValue: 0,
currencyInternalId: "T1|D MG 01|01",
increase: 0,
documentNumber: "000000000",
unitOfMeasureInternalid: "T1||XX",
customerVendorInternalId: "T1|D MG 01|999999|01|F",
companyInternalid: "T1|D MG 01",
decrease: 0,
totalPrice: 10,
apportionmentDate: "2019-04-11",
quantity: 1,
retentionValue: 0
}
],
taskInternalId: "T1|D MG 01|PRJ01|0001|001.01.01"
}
],
accountingClosingDate: "1800-01-01"
},
hasNext: false,
total: 1
}


Criando Testes para validar XML:


Bloco de código
titleExemplo de Testes
pm.test("Valida Status Retorno", function () {
    pm.expect(pm.response.code).to.be.oneOf([200]);
});

pm.test("Valida Conteúdo do Body - De/Para", function () {
    pm.expect(pm.response.text()).to.include("311D73CF-3B34-4ED6-A811-E07F7920A431");
});

...

View file
nameTreinamento_Project_001.postman_collection.json
height250

DBF da Tabela de Adapters.

View file
namexx499011.dbf
height150

...