Skip to content

chore: update xcode dependencies #4449

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

Merged
merged 1 commit into from
Mar 19, 2019
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/definitions/xcode.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
declare module "xcode" {
declare module "nativescript-dev-xcode" {
interface Options {
[key: string]: any;

Expand Down
2 changes: 1 addition & 1 deletion lib/node/xcode.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as xcode from "xcode";
import * as xcode from "nativescript-dev-xcode";

declare global {
type IXcode = typeof xcode;
Expand Down
127 changes: 70 additions & 57 deletions npm-shrinkwrap.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,15 @@
"minimatch": "3.0.2",
"mkdirp": "0.5.1",
"mute-stream": "0.0.5",
"nativescript-dev-xcode": "https://github.com/NativeScript/nativescript-dev-xcode/archive/master.tar.gz",
"nativescript-doctor": "1.8.1",
"nativescript-preview-sdk": "0.3.3",
"open": "0.0.5",
"ora": "2.0.0",
"osenv": "0.1.3",
"pacote": "8.1.6",
"pako": "1.0.6",
"pbxproj-dom": "1.0.11",
"pbxproj-dom": "1.1.0",
"plist": "1.1.0",
"plist-merge-patch": "0.1.1",
"proper-lockfile": "3.2.0",
Expand All @@ -83,7 +84,6 @@
"uuid": "3.0.1",
"winreg": "0.0.17",
"ws": "5.1.0",
"xcode": "https://github.com/NativeScript/node-xcode/archive/kddimitrov/rebase-upstream.tar.gz",
"xml2js": "0.4.19",
"xmldom": "0.1.21",
"yargs": "6.0.0",
Expand Down Expand Up @@ -133,4 +133,4 @@
"engines": {
"node": ">=8.0.0 <12.0.0"
}
}
}
18 changes: 10 additions & 8 deletions test/ios-project-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -697,7 +697,7 @@ describe("Source code support", () => {
return pbxProj;
};

it("adds source files as resources", async () => {
it("adds source files in Sources build phase", async () => {
const sourceFileNames = [
"src/Header.h", "src/ObjC.m",
"src/nested/Header.hpp", "src/nested/Source.cpp", "src/nested/ObjCpp.mm",
Expand All @@ -721,14 +721,15 @@ describe("Source code support", () => {

sourceFileNames.map(file => path.basename(file)).forEach(basename => {
const ext = path.extname(basename);
const shouldBeAdded = ext !== ".donotadd" && !ext.startsWith(".h");
const shouldBeAdded = ext !== ".donotadd";
assert.notEqual(pbxFileReferenceValues.indexOf(basename), -1, `${basename} not added to PBXFileRefereces`);

const buildPhaseFile = buildPhaseFiles.find((fileObject: any) => fileObject.comment.startsWith(basename));
if (shouldBeAdded) {
if (shouldBeAdded && !path.extname(basename).startsWith(".h")) {
assert.isDefined(buildPhaseFile, `${basename} not added to PBXSourcesBuildPhase`);
assert.include(buildPhaseFile.comment, "in Sources", `${basename} must be added to Sources group`);
} else {
assert.isUndefined(buildPhaseFile, `${basename} must not be added to Sources group`);
assert.isUndefined(buildPhaseFile, `${basename} is added to PBXSourcesBuildPhase, but it shouldn't have been.`);
}
});
});
Expand All @@ -749,14 +750,15 @@ describe("Source code support", () => {

sourceFileNames.map(file => path.basename(file)).forEach(basename => {
const ext = path.extname(basename);
const shouldBeAdded = ext !== ".donotadd" && !ext.startsWith(".h");
const buildPhaseFile = buildPhaseFiles.find((fileObject: any) => fileObject.comment.startsWith(basename));
const shouldBeAdded = ext !== ".donotadd";
assert.notEqual(pbxFileReferenceValues.indexOf(basename), -1, `${basename} not added to PBXFileRefereces`);
if (shouldBeAdded) {

const buildPhaseFile = buildPhaseFiles.find((fileObject: any) => fileObject.comment.startsWith(basename));
if (shouldBeAdded && !path.extname(basename).startsWith(".h")) {
assert.isDefined(buildPhaseFile, `${basename} not added to PBXSourcesBuildPhase`);
assert.include(buildPhaseFile.comment, "in Sources", `${basename} must be added to Sources group`);
} else {
assert.isUndefined(buildPhaseFile, `${basename} must not be added to Sources group`);
assert.isUndefined(buildPhaseFile, `${basename} was added to PBXSourcesBuildPhase, but it shouldn't have been`);
}
});
});
Expand Down