Skip to content

Commit

Permalink
URL may end in .app or .io
Browse files Browse the repository at this point in the history
  • Loading branch information
philnash committed May 7, 2023
1 parent 2fe8b55 commit f69f1c3
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions test/ngrok.registered.paid.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ let tunnelUrl, respBody;
});

it("should return url pointing to ngrok domain", function () {
expect(tunnelUrl).to.match(/https:\/\/.(.*).ngrok.app/);
expect(tunnelUrl).to.match(/https:\/\/.(.*).ngrok.(app|io)/);
});

describe("calling local server through ngrok", function () {
Expand Down Expand Up @@ -107,7 +107,9 @@ let tunnelUrl, respBody;
});

it("should return ngrok url with a given subdomain", function () {
expect(tunnelUrl).to.equal("https://" + uniqDomain + ".ngrok.app");
expect(tunnelUrl).to.match(
new RegExp(`https://${uniqDomain}.ngrok.(app|io)`)
);
});

describe("calling local server through ngrok", function () {
Expand Down Expand Up @@ -158,8 +160,8 @@ let tunnelUrl, respBody;
});

it("should be able to connect and return the same ngrok url", function () {
expect(tunnelUrl).to.equal(
"https://" + uniqDomain + ".ngrok.app"
expect(tunnelUrl).to.match(
new RegExp(`https://${uniqDomain}.ngrok.(app|io)`)
);
});
});
Expand All @@ -174,7 +176,7 @@ let tunnelUrl, respBody;
});

it("should return url pointing to ngrok domain", function () {
expect(tunnelUrl).to.match(/https:\/\/.(.*).ngrok.app/);
expect(tunnelUrl).to.match(/https:\/\/.(.*).ngrok.(app|io)/);
});

describe("calling local server through ngrok without http authorization", function () {
Expand Down

0 comments on commit f69f1c3

Please sign in to comment.