Skip to content

Commit

Permalink
Merge cc4358f into ff99d8a
Browse files Browse the repository at this point in the history
  • Loading branch information
omenocal committed Oct 23, 2018
2 parents ff99d8a + cc4358f commit 94733db
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 18 deletions.
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "voxa",
"version": "3.0.0-alpha32",
"version": "3.0.0-alpha33",
"description": "A fsm (state machine) framework for Alexa apps using Node.js",
"main": "./lib/src/index.js",
"types": "./lib/src/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion src/platforms/alexa/apis/ApiBase.ts
Expand Up @@ -34,7 +34,7 @@ export class ApiBase {
this.rawEvent = _.cloneDeep(event);
}

protected getResult(path = "", method = "GET", body = {}) {
protected getResult(path = "", method = "GET", body?: any) {
const options = {
body,
headers: {
Expand Down
20 changes: 4 additions & 16 deletions test/alexa/Lists.spec.ts
Expand Up @@ -128,12 +128,9 @@ describe("Lists", () => {

it("should create a custom list and create an item", async () => {
const reqheaders = {
"accept": "application/json",
"authorization": `Bearer ${
authorization: `Bearer ${
event.context.System.user.permissions.consentToken
}`,
"content-type": "application/json",
"host": "api.amazonalexa.com",
};

nock("https://api.amazonalexa.com", { reqheaders })
Expand Down Expand Up @@ -193,12 +190,9 @@ describe("Lists", () => {

it("should modify custom list, and modify an item", async () => {
const reqheaders = {
"accept": "application/json",
"authorization": `Bearer ${
authorization: `Bearer ${
event.context.System.user.permissions.consentToken
}`,
"content-type": "application/json",
"host": "api.amazonalexa.com",
};

const value = "NEW NAME";
Expand Down Expand Up @@ -281,12 +275,9 @@ describe("Lists", () => {

it("should delete item from list, and delete list", async () => {
const reqheaders = {
"accept": "application/json",
"authorization": `Bearer ${
authorization: `Bearer ${
event.context.System.user.permissions.consentToken
}`,
"content-type": "application/json",
"host": "api.amazonalexa.com",
};

const value = "NEW NAME";
Expand Down Expand Up @@ -325,12 +316,9 @@ describe("Lists", () => {

it("should show the lists with at least 1 item", async () => {
const reqheaders = {
"accept": "application/json",
"authorization": `Bearer ${
authorization: `Bearer ${
event.context.System.user.permissions.consentToken
}`,
"content-type": "application/json",
"host": "api.amazonalexa.com",
};

const value = "NEW NAME";
Expand Down

0 comments on commit 94733db

Please sign in to comment.