Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: update tests to use new src path #904

Merged
merged 1 commit into from Jan 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion spec/integration.spec.js
@@ -1,4 +1,4 @@
import twilio from "../lib/";
import twilio from "../src/";

var accountSid = "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa";
var token = "token";
Expand Down
2 changes: 1 addition & 1 deletion spec/integration/holodeck.js
@@ -1,5 +1,5 @@
import util from "util";
import Request from "../../lib/http/request";
import Request from "../../src/http/request";
import moduleInfo from "../../package.json";
import os from "os";

Expand Down
2 changes: 1 addition & 1 deletion spec/unit/base/RequestClient.spec.js
@@ -1,6 +1,6 @@
import mockfs from "mock-fs";
import axios from "axios";
import RequestClient from "../../../lib/base/RequestClient";
import RequestClient from "../../../src/base/RequestClient";
import HttpsProxyAgent from "https-proxy-agent";
import http from "http";

Expand Down
2 changes: 1 addition & 1 deletion spec/unit/base/RestException.spec.ts
@@ -1,4 +1,4 @@
import RestException from "../../../lib/base/RestException";
import RestException from "../../../src/base/RestException";

describe("exception gets created from string", function () {
it("should test serialize without details", function () {
Expand Down
6 changes: 3 additions & 3 deletions spec/unit/base/Version.spec.js
@@ -1,7 +1,7 @@
import Version from "../../../lib/base/Version";
import Version from "../../../src/base/Version";
import Holodeck from "../../integration/holodeck";
import Response from "../../../lib/http/response";
import Twilio from "../../../lib";
import Response from "../../../src/http/response";
import Twilio from "../../../src";

describe("fetch method", function () {
it("should not throw an exception on 3xx status code", function (done) {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/base/deserialize.spec.js
@@ -1,4 +1,4 @@
import * as deserialize from "../../../lib/base/deserialize";
import * as deserialize from "../../../src/base/deserialize";

describe("deserialize date tests", function () {
it("should parse date", function () {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/base/serialize.spec.js
@@ -1,4 +1,4 @@
import * as serialize from "../../../lib/base/serialize";
import * as serialize from "../../../src/base/serialize";

describe("serialize date tests", function () {
it("should be unable to serialize undefined date", function () {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/base/utility.spec.ts
@@ -1,4 +1,4 @@
import { isValidPathParam } from "../../../lib/base/utility";
import { isValidPathParam } from "../../../src/base/utility";

describe("isValidPathParam", () => {
it("should validate path params", () => {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/jwt/AccessToken.spec.js
@@ -1,4 +1,4 @@
import twilio from "../../../";
import twilio from "../../../src";
import jwt from "jsonwebtoken";

process.noDeprecation = true;
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/jwt/ClientCapability.spec.js
@@ -1,4 +1,4 @@
import ClientCapability from "../../../lib/jwt/ClientCapability";
import ClientCapability from "../../../src/jwt/ClientCapability";
import jwt from "jsonwebtoken";

describe("The TwiML Capability Token Object", function () {
Expand Down
4 changes: 2 additions & 2 deletions spec/unit/jwt/taskrouter/TaskRouterCapability.spec.js
@@ -1,5 +1,5 @@
import TaskRouterCapability from "../../../../lib/jwt/taskrouter/TaskRouterCapability";
import * as util from "../../../../lib/jwt/taskrouter/util";
import TaskRouterCapability from "../../../../src/jwt/taskrouter/TaskRouterCapability";
import * as util from "../../../../src/jwt/taskrouter/util";
import jwt from "jsonwebtoken";

describe("The TaskRouter Capability Token Object", function () {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/jwt/taskrouter/util.spec.js
@@ -1,4 +1,4 @@
import * as util from "../../../../lib/jwt/taskrouter/util";
import * as util from "../../../../src/jwt/taskrouter/util";

describe("util", function () {
describe("url utils", function () {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/rest/Twilio.spec.js
@@ -1,5 +1,5 @@
import nock from "nock";
import Twilio from "../../../lib/";
import Twilio from "../../../src/";

describe("client", () => {
let client;
Expand Down
4 changes: 2 additions & 2 deletions spec/unit/rest/incomingPhoneNumber.spec.js
@@ -1,6 +1,6 @@
import Holodeck from "../../integration/holodeck";
import Response from "../../../lib/http/response";
import Twilio from "../../../lib/";
import Response from "../../../src/http/response";
import Twilio from "../../../src/";

var client;
var holodeck;
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/twiml/MessagingResponse.spec.js
@@ -1,6 +1,6 @@
process.noDeprecation = true;

import MessagingResponse from "../../../lib/twiml/MessagingResponse";
import MessagingResponse from "../../../src/twiml/MessagingResponse";

describe("create messaging response TwiML", function () {
it("should serialize empty response", function () {
Expand Down
2 changes: 1 addition & 1 deletion spec/unit/twiml/VoiceResponse.spec.js
@@ -1,6 +1,6 @@
process.noDeprecation = true;

import VoiceResponse from "../../../lib/twiml/VoiceResponse";
import VoiceResponse from "../../../src/twiml/VoiceResponse";

describe("create voice response TwiML", function () {
it("should serialize empty response", function () {
Expand Down
2 changes: 1 addition & 1 deletion spec/validation.spec.js
Expand Up @@ -3,7 +3,7 @@ import {
validateRequestWithBody,
validateBody,
webhook,
} from "../lib/webhooks/webhooks";
} from "../src/webhooks/webhooks";
import httpMocks from "node-mocks-http";
import url from "url";

Expand Down