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

Bump ua-parser-js from 0.7.31 to 0.7.34 #251

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
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
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
"path": "^0.12.7",
"semver": "^7.3.7",
"sls-version": "^2.1.0",
"ts-simple-ast": "^11.3.0",
"tslib": "^1.9.3",
"ts-morph": "^17.0.1",
"tslib": "^2.5.0",
"yargs": "^11.1.0"
},
"devDependencies": {
Expand All @@ -46,7 +46,7 @@
"@types/lodash": "^4.14.117",
"@types/mkdirp": "^1.0.2",
"@types/nock": "^9.3.0",
"@types/node": "^16.11.7",
"@types/node": "^18.14.6",
"@types/node-dir": "^0.0.30",
"@types/semver": "^7.3.10",
"@types/tempy": "^0.1.0",
Expand All @@ -68,7 +68,7 @@
"ts-jest": "^27.0.7",
"ts-loader": "^9.3.1",
"tslint": "^6.0.0",
"typescript": "~4.4.4",
"typescript": "~4.9.5",
"webpack": "^5.73.0",
"webpack-cli": "^4.10.0"
},
Expand Down
15 changes: 12 additions & 3 deletions src/commands/generate/__tests__/importsTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
*/

import { IType, ITypeDefinition, PrimitiveType } from "conjure-api";
import { ImportDeclarationStructure, StructureKind } from "ts-morph";
import { ImportsVisitor, sortImports } from "../imports";
import { createHashableTypeName } from "../utils";
import { FLAVORED_TYPE_GENERATION_FLAGS } from "./resources/constants";
Expand Down Expand Up @@ -59,8 +60,9 @@ describe("imports", () => {
GENERATION_FLAGS_TO_USE_FOR_IMPORTS,
);

function namedImport(moduleSpecifier: string, name: string) {
function namedImport(moduleSpecifier: string, name: string): ImportDeclarationStructure {
return {
kind: StructureKind.ImportDeclaration,
moduleSpecifier,
namedImports: [{ name }],
};
Expand Down Expand Up @@ -176,7 +178,7 @@ describe("imports", () => {
it("adds both named and namespace imports", async () => {
const imports = sortImports([
namedImport("module", "name"),
{ moduleSpecifier: "module", namespaceImport: "namespace" },
{ kind: StructureKind.ImportDeclaration, moduleSpecifier: "module", namespaceImport: "namespace" },
]);
expect(imports.length).toEqual(2);
});
Expand All @@ -185,6 +187,7 @@ describe("imports", () => {
const sort = () =>
sortImports([
{
kind: StructureKind.ImportDeclaration,
moduleSpecifier: "module",
namedImports: [{ name: "name" }],
namespaceImport: "namespace",
Expand All @@ -197,10 +200,12 @@ describe("imports", () => {
const sort = () =>
sortImports([
{
kind: StructureKind.ImportDeclaration,
moduleSpecifier: "module",
namespaceImport: "namespace",
},
{
kind: StructureKind.ImportDeclaration,
moduleSpecifier: "module",
namespaceImport: "anotherNamespace",
},
Expand All @@ -225,7 +230,11 @@ describe("imports", () => {
GENERATION_FLAGS_TO_USE_FOR_IMPORTS,
);
expect(IType.visit(IType.reference(otherType), importVisistor)).toEqual([
{ moduleSpecifier: "../foo-request/bar", namedImports: [{ name: "I" + otherType.name }] },
{
kind: StructureKind.ImportDeclaration,
moduleSpecifier: "../foo-request/bar",
namedImports: [{ name: "I" + otherType.name }],
},
]);
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,17 @@ import { IAliasedString } from "../product/aliasedString";
import { ICreateDatasetRequest } from "../product/createDatasetRequest";
import { IHttpApiBridge } from "conjure-client";

/**
* Constant reference to `undefined` that we expect to get minified and therefore reduce total code size
*/
/** Constant reference to `undefined` that we expect to get minified and therefore reduce total code size */
const __undefined: undefined = undefined;

/**
* A Markdown description of the service.
*
*
*/
export interface ITestService {
/**
* Returns a mapping from file system id to backing file system configuration.
*
*
*/
getFileSystems(): Promise<{ [key: string]: IBackingFileSystem }>;
createDataset(request: ICreateDatasetRequest, testHeaderArg: string): Promise<IDataset>;
Expand All @@ -30,7 +28,7 @@ export interface ITestService {
getBranches(datasetRid: string): Promise<Array<string>>;
/**
* Gets all branches of this dataset.
*
*
* @deprecated use getBranches instead
*/
getBranchesDeprecated(datasetRid: string): Promise<Array<string>>;
Expand All @@ -51,7 +49,7 @@ export class TestService {

/**
* Returns a mapping from file system id to backing file system configuration.
*
*
*/
public getFileSystems(): Promise<{ [key: string]: IBackingFileSystem }> {
return this.bridge.call<{ [key: string]: IBackingFileSystem }>(
Expand Down Expand Up @@ -219,7 +217,7 @@ export class TestService {

/**
* Gets all branches of this dataset.
*
*
* @deprecated use getBranches instead
*/
public getBranchesDeprecated(datasetRid: string): Promise<Array<string>> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
export interface IBackingFileSystem {
/**
* The name by which this file system is identified.
*/
/** The name by which this file system is identified. */
'fileSystemId': string;
'baseUri': string;
'configuration': { [key: string]: string };
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
export interface IDataset {
'fileSystemId': string;
/**
* Uniquely identifies this dataset.
*/
/** Uniquely identifies this dataset. */
'rid': string;
}
Original file line number Diff line number Diff line change
@@ -1,20 +1,18 @@
export namespace DeprecatedEnumExample {
export type ONE = "ONE";
/**
* @deprecated use ONE
*/
/** @deprecated use ONE */
export type OLD_ONE = "OLD_ONE";
/**
* You should no longer use this
*
*
* @deprecated use ONE
*/
export type OLD_DEPRECATED_ONE = "OLD_DEPRECATED_ONE";
/**
* You should no longer use this
*
*
* @deprecated should use ONE
*
*
*/
export type OLD_DOCUMENTED_ONE = "OLD_DOCUMENTED_ONE";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,18 @@
export interface IDeprecatedFieldExample {
'one': string;
/**
* @deprecated use ONE
*/
/** @deprecated use ONE */
'deprecatedOne': string;
/**
* You should no longer use this
*
*
* @deprecated use ONE
*/
'documentedDeprecatedOne': string;
/**
* You should no longer use this
*
*
* @deprecated should use ONE
*
*
*/
'deprecatedWithinDocumentOne': string;
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@ export interface IDeprecatedUnion_Good {
'type': "good";
}

/**
* @deprecated use good
*/
/** @deprecated use good */
export interface IDeprecatedUnion_NoGood {
'noGood': string;
'type': "noGood";
Expand Down Expand Up @@ -35,9 +33,7 @@ function isNoGood(obj: IDeprecatedUnion): obj is IDeprecatedUnion_NoGood {
return (obj.type === "noGood");
}

/**
* @deprecated use good
*/
/** @deprecated use good */
function noGood(obj: string): IDeprecatedUnion_NoGood {
return {
noGood: obj,
Expand All @@ -49,9 +45,7 @@ function isNoGoodDoc(obj: IDeprecatedUnion): obj is IDeprecatedUnion_NoGoodDoc {
return (obj.type === "noGoodDoc");
}

/**
* @deprecated use good
*/
/** @deprecated use good */
function noGoodDoc(obj: string): IDeprecatedUnion_NoGoodDoc {
return {
noGoodDoc: obj,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
/**
* This enumerates the numbers 1:2 also 100.
*
*
*/
export namespace EnumExample {
export type ONE = "ONE";
export type TWO = "TWO";
/**
* Value of 100.
*/
/** Value of 100. */
export type ONE_HUNDRED = "ONE_HUNDRED";

export const ONE = "ONE" as "ONE";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,36 +1,20 @@
import { IStringAliasExample } from "./stringAliasExample";

export interface IManyFieldExample {
/**
* docs for string field
*/
/** docs for string field */
'string': string;
/**
* docs for integer field
*/
/** docs for integer field */
'integer': number;
/**
* docs for doubleValue field
*/
/** docs for doubleValue field */
'doubleValue': number | "NaN";
/**
* docs for optionalItem field
*/
/** docs for optionalItem field */
'optionalItem'?: string | null;
/**
* docs for items field
*/
/** docs for items field */
'items': Array<string>;
/**
* docs for set field
*/
/** docs for set field */
'set': Array<string>;
/**
* docs for map field
*/
/** docs for map field */
'map': { [key: string]: string };
/**
* docs for alias field
*/
/** docs for alias field */
'alias': IStringAliasExample;
}
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import { IStringExample } from "./stringExample";

/**
* Docs for when UnionTypeExample is of type StringExample.
*/
/** Docs for when UnionTypeExample is of type StringExample. */
export interface IUnionTypeExample_StringExample {
'stringExample': IStringExample;
'type': "stringExample";
Expand Down Expand Up @@ -115,9 +113,7 @@ function interface_(obj: number): IUnionTypeExample_Interface {
};
}

/**
* A type which can either be a StringExample, a set of strings, or an integer.
*/
/** A type which can either be a StringExample, a set of strings, or an integer. */
export type IUnionTypeExample = IUnionTypeExample_StringExample | IUnionTypeExample_Set | IUnionTypeExample_ThisFieldIsAnInteger | IUnionTypeExample_AlsoAnInteger | IUnionTypeExample_If | IUnionTypeExample_New | IUnionTypeExample_Interface;

export interface IUnionTypeExampleVisitor<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,17 @@ import { IDataset } from "../product-datasets/dataset";
import { ICreateDatasetRequest } from "../product/createDatasetRequest";
import { IHttpApiBridge } from "conjure-client";

/**
* Constant reference to `undefined` that we expect to get minified and therefore reduce total code size
*/
/** Constant reference to `undefined` that we expect to get minified and therefore reduce total code size */
const __undefined: undefined = undefined;

/**
* A Markdown description of the service.
*
*
*/
export interface ITestService {
/**
* Returns a mapping from file system id to backing file system configuration.
*
*
*/
getFileSystems(): Promise<{ readonly [key: string]: IBackingFileSystem }>;
createDataset(request: ICreateDatasetRequest, testHeaderArg: string): Promise<IDataset>;
Expand All @@ -29,7 +27,7 @@ export interface ITestService {
getBranches(datasetRid: string): Promise<ReadonlyArray<string>>;
/**
* Gets all branches of this dataset.
*
*
* @deprecated use getBranches instead
*/
getBranchesDeprecated(datasetRid: string): Promise<ReadonlyArray<string>>;
Expand All @@ -50,7 +48,7 @@ export class TestService {

/**
* Returns a mapping from file system id to backing file system configuration.
*
*
*/
public getFileSystems(): Promise<{ readonly [key: string]: IBackingFileSystem }> {
return this.bridge.call<{ readonly [key: string]: IBackingFileSystem }>(
Expand Down Expand Up @@ -218,7 +216,7 @@ export class TestService {

/**
* Gets all branches of this dataset.
*
*
* @deprecated use getBranches instead
*/
public getBranchesDeprecated(datasetRid: string): Promise<ReadonlyArray<string>> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
export interface IBackingFileSystem {
/**
* The name by which this file system is identified.
*/
/** The name by which this file system is identified. */
readonly 'fileSystemId': string;
readonly 'baseUri': string;
readonly 'configuration': { readonly [key: string]: string };
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
export interface IDataset {
readonly 'fileSystemId': string;
/**
* Uniquely identifies this dataset.
*/
/** Uniquely identifies this dataset. */
readonly 'rid': string;
}
Loading