mirror of
https://github.com/marcogll/passkit-generator.git
synced 2026-03-15 13:25:19 +00:00
Fixed tests for iOS 26
This commit is contained in:
@@ -1276,7 +1276,7 @@ describe("PKPass", () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("eventTicket new layout", () => {
|
describe("iOS 18 / iOS 26 new layouts", () => {
|
||||||
it("should contain preferredStyleSchemes if coming from an imported pass json", () => {
|
it("should contain preferredStyleSchemes if coming from an imported pass json", () => {
|
||||||
const passjson = modelFiles["pass.json"];
|
const passjson = modelFiles["pass.json"];
|
||||||
const changedPassJson = Buffer.from(
|
const changedPassJson = Buffer.from(
|
||||||
@@ -1355,16 +1355,16 @@ describe("PKPass", () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
it("preferredStyleSchemes setter should throw if pass is not an eventTicket", () => {
|
it("preferredStyleSchemes setter should throw if pass is not an eventTicket or boardingPass", () => {
|
||||||
pkpass.type = "boardingPass";
|
pkpass.type = "storeCard";
|
||||||
|
|
||||||
expect(() => {
|
expect(() => {
|
||||||
pkpass.preferredStyleSchemes = ["posterEventTicket", "eventTicket"];
|
pkpass.preferredStyleSchemes = ["posterEventTicket", "eventTicket"];
|
||||||
}).toThrowError();
|
}).toThrowError();
|
||||||
});
|
});
|
||||||
|
|
||||||
it("preferredStyleSchemes getter should throw if pass is not an eventTicket", () => {
|
it("preferredStyleSchemes getter should throw if pass is not an eventTicket or boardingPass", () => {
|
||||||
pkpass.type = "boardingPass";
|
pkpass.type = "storeCard";
|
||||||
|
|
||||||
expect(() => {
|
expect(() => {
|
||||||
pkpass.preferredStyleSchemes;
|
pkpass.preferredStyleSchemes;
|
||||||
|
|||||||
Reference in New Issue
Block a user