Skip to content

Commit

Permalink
update test to use promises
Browse files Browse the repository at this point in the history
  • Loading branch information
dlsteuer committed Jul 7, 2020
1 parent 1bdadba commit 7e5fae4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/integration/integration.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ describe("Integration", () => {
});

it("lists templates", done => {
templates.getTemplates(version, {}, (error, data) => {
templates.getTemplates(version, {}).then((error, data) => {
if (error) {
done(error);
return;
Expand All @@ -36,7 +36,7 @@ describe("Integration", () => {

it("gets a single template", done => {
const id = "tem_01de5teh6k59kya8q92mb01qzq"
templates.getTemplateById(id, "handlebars", version, (error, data) => {
templates.getTemplateById(id, "handlebars", version).then((error, data) => {
if (error) {
done(error);
return;
Expand All @@ -47,7 +47,7 @@ describe("Integration", () => {
});

it("lists drafts", done => {
drafts.getDrafts(version, {}, (error, data) => {
drafts.getDrafts(version, {}).then((error, data) => {
if (error) {
done(error);
return;
Expand All @@ -59,7 +59,7 @@ describe("Integration", () => {

it("gets a single draft", done => {
const id = "tdft_01dxkwr0nevs5h2baa3n3dgktp"
drafts.getDraftById(id, "handlebars", version, (error, data) => {
drafts.getDraftById(id, "handlebars", version).then((error, data) => {
if (error) {
done(error);
return;
Expand Down

0 comments on commit 7e5fae4

Please sign in to comment.