mirror of
https://github.com/usebruno/bruno.git
synced 2024-11-23 00:13:24 +01:00
Merge pull request #733 from survivant/bugfix/import-postman-scripts
[bugfix] Put scripts in comments in Postman import
This commit is contained in:
commit
34ea7f0673
@ -68,13 +68,13 @@ const importPostmanV2CollectionItem = (brunoParent, item) => {
|
|||||||
if (!brunoRequestItem.request.script) {
|
if (!brunoRequestItem.request.script) {
|
||||||
brunoRequestItem.request.script = {};
|
brunoRequestItem.request.script = {};
|
||||||
}
|
}
|
||||||
brunoRequestItem.request.script.req = event.script.exec[0];
|
brunoRequestItem.request.script.req = `/* ${event.script.exec[0]} */`;
|
||||||
}
|
}
|
||||||
if (event.listen === 'test' && event.script && event.script.exec) {
|
if (event.listen === 'test' && event.script && event.script.exec) {
|
||||||
if (!brunoRequestItem.request.tests) {
|
if (!brunoRequestItem.request.tests) {
|
||||||
brunoRequestItem.request.tests = {};
|
brunoRequestItem.request.tests = {};
|
||||||
}
|
}
|
||||||
brunoRequestItem.request.tests = event.script.exec[0];
|
brunoRequestItem.request.tests = `/* ${event.script.exec[0]} */`;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user