From 15e5e413d9a49012202c46f8fde747c1593ec0f1 Mon Sep 17 00:00:00 2001 From: Eugen Wissner Date: Sat, 10 Nov 2018 20:06:38 +0100 Subject: Add code --- async/features/steps/async.js | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 async/features/steps/async.js (limited to 'async/features/steps/async.js') diff --git a/async/features/steps/async.js b/async/features/steps/async.js new file mode 100644 index 0000000..ea88856 --- /dev/null +++ b/async/features/steps/async.js @@ -0,0 +1,9 @@ +import { When } from 'cucumber' +import axios from 'axios' + +When('I request the same resource twice', async function () { + const url = 'http://localhost:8080/' + + this.first = await axios.request(url).data + this.second = await axios.request(url).data +}) -- cgit v1.2.3