diff --git a/.swagger-codegen/VERSION b/.swagger-codegen/VERSION index 855ff95..3eb2ae3 100644 --- a/.swagger-codegen/VERSION +++ b/.swagger-codegen/VERSION @@ -1 +1 @@ -2.4.0-SNAPSHOT \ No newline at end of file +2.4.14 \ No newline at end of file diff --git a/Makefile b/Makefile index 0188341..aeb45a3 100644 --- a/Makefile +++ b/Makefile @@ -17,5 +17,4 @@ gen: -D licenseName="Apache 2.0" \ -D projectDescription="jsflagr is a Javascript client SDK for Flagr." \ -o /local/ - git co -- package.json - git co -- package-lock.json + npm i && npm audit fix --force diff --git a/README.md b/README.md index 620923a..b2d88e7 100644 --- a/README.md +++ b/README.md @@ -4,8 +4,8 @@ Jsflagr - JavaScript client for jsflagr Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project: -- API version: 1.1.0 -- Package version: 1.1.0 +- API version: 1.1.10 +- Package version: 1.1.10 - Build package: io.swagger.codegen.languages.JavascriptClientCodegen ## Installation @@ -129,7 +129,8 @@ Class | Method | HTTP request | Description *Jsflagr.DistributionApi* | [**putDistributions**](docs/DistributionApi.md#putDistributions) | **PUT** /flags/{flagID}/segments/{segmentID}/distributions | *Jsflagr.EvaluationApi* | [**postEvaluation**](docs/EvaluationApi.md#postEvaluation) | **POST** /evaluation | *Jsflagr.EvaluationApi* | [**postEvaluationBatch**](docs/EvaluationApi.md#postEvaluationBatch) | **POST** /evaluation/batch | -*Jsflagr.ExportApi* | [**getExportSQLite**](docs/ExportApi.md#getExportSQLite) | **GET** /export/sqlite | +*Jsflagr.ExportApi* | [**getExportEvalCacheJSON**](docs/ExportApi.md#getExportEvalCacheJSON) | **GET** /export/eval_cache/json | +*Jsflagr.ExportApi* | [**getExportSqlite**](docs/ExportApi.md#getExportSqlite) | **GET** /export/sqlite | *Jsflagr.FlagApi* | [**createFlag**](docs/FlagApi.md#createFlag) | **POST** /flags | *Jsflagr.FlagApi* | [**deleteFlag**](docs/FlagApi.md#deleteFlag) | **DELETE** /flags/{flagID} | *Jsflagr.FlagApi* | [**findFlags**](docs/FlagApi.md#findFlags) | **GET** /flags | @@ -144,6 +145,10 @@ Class | Method | HTTP request | Description *Jsflagr.SegmentApi* | [**findSegments**](docs/SegmentApi.md#findSegments) | **GET** /flags/{flagID}/segments | *Jsflagr.SegmentApi* | [**putSegment**](docs/SegmentApi.md#putSegment) | **PUT** /flags/{flagID}/segments/{segmentID} | *Jsflagr.SegmentApi* | [**putSegmentsReorder**](docs/SegmentApi.md#putSegmentsReorder) | **PUT** /flags/{flagID}/segments/reorder | +*Jsflagr.TagApi* | [**createTag**](docs/TagApi.md#createTag) | **POST** /flags/{flagID}/tags | +*Jsflagr.TagApi* | [**deleteTag**](docs/TagApi.md#deleteTag) | **DELETE** /flags/{flagID}/tags/{tagID} | +*Jsflagr.TagApi* | [**findAllTags**](docs/TagApi.md#findAllTags) | **GET** /tags | +*Jsflagr.TagApi* | [**findTags**](docs/TagApi.md#findTags) | **GET** /flags/{flagID}/tags | *Jsflagr.VariantApi* | [**createVariant**](docs/VariantApi.md#createVariant) | **POST** /flags/{flagID}/variants | *Jsflagr.VariantApi* | [**deleteVariant**](docs/VariantApi.md#deleteVariant) | **DELETE** /flags/{flagID}/variants/{variantID} | *Jsflagr.VariantApi* | [**findVariants**](docs/VariantApi.md#findVariants) | **GET** /flags/{flagID}/variants | @@ -156,6 +161,7 @@ Class | Method | HTTP request | Description - [Jsflagr.CreateConstraintRequest](docs/CreateConstraintRequest.md) - [Jsflagr.CreateFlagRequest](docs/CreateFlagRequest.md) - [Jsflagr.CreateSegmentRequest](docs/CreateSegmentRequest.md) + - [Jsflagr.CreateTagRequest](docs/CreateTagRequest.md) - [Jsflagr.CreateVariantRequest](docs/CreateVariantRequest.md) - [Jsflagr.Distribution](docs/Distribution.md) - [Jsflagr.Error](docs/Error.md) @@ -167,6 +173,7 @@ Class | Method | HTTP request | Description - [Jsflagr.EvaluationEntity](docs/EvaluationEntity.md) - [Jsflagr.Flag](docs/Flag.md) - [Jsflagr.FlagSnapshot](docs/FlagSnapshot.md) + - [Jsflagr.Health](docs/Health.md) - [Jsflagr.PutDistributionsRequest](docs/PutDistributionsRequest.md) - [Jsflagr.PutFlagRequest](docs/PutFlagRequest.md) - [Jsflagr.PutSegmentReorderRequest](docs/PutSegmentReorderRequest.md) @@ -175,6 +182,7 @@ Class | Method | HTTP request | Description - [Jsflagr.Segment](docs/Segment.md) - [Jsflagr.SegmentDebugLog](docs/SegmentDebugLog.md) - [Jsflagr.SetFlagEnabledRequest](docs/SetFlagEnabledRequest.md) + - [Jsflagr.Tag](docs/Tag.md) - [Jsflagr.Variant](docs/Variant.md) diff --git a/docs/CreateFlagRequest.md b/docs/CreateFlagRequest.md index aa17458..eb4e200 100644 --- a/docs/CreateFlagRequest.md +++ b/docs/CreateFlagRequest.md @@ -5,5 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **description** | **String** | | **key** | **String** | unique key representation of the flag | [optional] +**template** | **String** | template for flag creation | [optional] diff --git a/docs/CreateTagRequest.md b/docs/CreateTagRequest.md new file mode 100644 index 0000000..47c2f93 --- /dev/null +++ b/docs/CreateTagRequest.md @@ -0,0 +1,8 @@ +# Jsflagr.CreateTagRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**value** | **String** | | + + diff --git a/docs/EvalContext.md b/docs/EvalContext.md index 9fa3092..b63c736 100644 --- a/docs/EvalContext.md +++ b/docs/EvalContext.md @@ -3,11 +3,12 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**entityID** | **String** | entityID is used to deterministically at random to evaluate the flag result. If it's empty, flagr will randomly generate one. | [optional] +**entityID** | **String** | entityID is used to deterministically at random to evaluate the flag result. If it's empty, flagr will randomly generate one. | [optional] **entityType** | **String** | | [optional] **entityContext** | **Object** | | [optional] **enableDebug** | **Boolean** | | [optional] **flagID** | **Number** | flagID | [optional] **flagKey** | **String** | flagKey. flagID or flagKey will resolve to the same flag. Either works. | [optional] +**flagTags** | **[String]** | flagTags. flagTags looks up flags by tag. Either works. | [optional] diff --git a/docs/EvaluationBatchRequest.md b/docs/EvaluationBatchRequest.md index 0eb1bd8..a7f61f7 100644 --- a/docs/EvaluationBatchRequest.md +++ b/docs/EvaluationBatchRequest.md @@ -6,6 +6,7 @@ Name | Type | Description | Notes **entities** | [**[EvaluationEntity]**](EvaluationEntity.md) | | **enableDebug** | **Boolean** | | [optional] **flagIDs** | **[Number]** | flagIDs | [optional] -**flagKeys** | **[String]** | flagKeys. Either flagIDs or flagKeys works. If pass in both, Flagr may return duplicate results. | [optional] +**flagKeys** | **[String]** | flagKeys. Either flagIDs, flagKeys or flagTags works. If pass in multiples, Flagr may return duplicate results. | [optional] +**flagTags** | **[String]** | flagTags. Either flagIDs, flagKeys or flagTags works. If pass in multiples, Flagr may return duplicate results. | [optional] diff --git a/docs/ExportApi.md b/docs/ExportApi.md index febc7cc..197a54e 100644 --- a/docs/ExportApi.md +++ b/docs/ExportApi.md @@ -4,16 +4,17 @@ All URIs are relative to *http://localhost/api/v1* Method | HTTP request | Description ------------- | ------------- | ------------- -[**getExportSQLite**](ExportApi.md#getExportSQLite) | **GET** /export/sqlite | +[**getExportEvalCacheJSON**](ExportApi.md#getExportEvalCacheJSON) | **GET** /export/eval_cache/json | +[**getExportSqlite**](ExportApi.md#getExportSqlite) | **GET** /export/sqlite | - -# **getExportSQLite** -> File getExportSQLite() + +# **getExportEvalCacheJSON** +> Object getExportEvalCacheJSON() -Export sqlite3 format of the db dump, which is converted from the main database. +Export JSON format of the eval cache dump ### Example ```javascript @@ -28,7 +29,7 @@ var callback = function(error, data, response) { console.log('API called successfully. Returned data: ' + data); } }; -apiInstance.getExportSQLite(callback); +apiInstance.getExportEvalCacheJSON(callback); ``` ### Parameters @@ -36,6 +37,53 @@ This endpoint does not need any parameter. ### Return type +**Object** + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **getExportSqlite** +> File getExportSqlite(opts) + + + +Export sqlite3 format of the db dump, which is converted from the main database. + +### Example +```javascript +var Jsflagr = require('jsflagr'); + +var apiInstance = new Jsflagr.ExportApi(); + +var opts = { + 'excludeSnapshots': true // Boolean | export without snapshots data - useful for smaller db without snapshots +}; + +var callback = function(error, data, response) { + if (error) { + console.error(error); + } else { + console.log('API called successfully. Returned data: ' + data); + } +}; +apiInstance.getExportSqlite(opts, callback); +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **excludeSnapshots** | **Boolean**| export without snapshots data - useful for smaller db without snapshots | [optional] + +### Return type + **File** ### Authorization diff --git a/docs/Flag.md b/docs/Flag.md index cc72252..62a41b2 100644 --- a/docs/Flag.md +++ b/docs/Flag.md @@ -7,10 +7,12 @@ Name | Type | Description | Notes **key** | **String** | unique key representation of the flag | [optional] **description** | **String** | | **enabled** | **Boolean** | | +**tags** | [**[Tag]**](Tag.md) | | [optional] **segments** | [**[Segment]**](Segment.md) | | [optional] **variants** | [**[Variant]**](Variant.md) | | [optional] **dataRecordsEnabled** | **Boolean** | enabled data records will get data logging in the metrics pipeline, for example, kafka. | -**entityType** | **String** | it will override the entityType in the evaluation logs if it's not empty | [optional] +**entityType** | **String** | it will override the entityType in the evaluation logs if it's not empty | [optional] +**notes** | **String** | flag usage details in markdown format | [optional] **createdBy** | **String** | | [optional] **updatedBy** | **String** | | [optional] **updatedAt** | **Date** | | [optional] diff --git a/docs/FlagApi.md b/docs/FlagApi.md index 92b3b44..7fd39cf 100644 --- a/docs/FlagApi.md +++ b/docs/FlagApi.md @@ -118,6 +118,7 @@ var opts = { 'limit': 789, // Number | the numbers of flags to return 'enabled': true, // Boolean | return flags having given enabled status 'description': "description_example", // String | return flags exactly matching given description + 'tags': "tags_example", // String | return flags with the given tags (comma separated) 'descriptionLike': "descriptionLike_example", // String | return flags partially matching given description 'key': "key_example", // String | return flags matching given key 'offset': 789, // Number | return flags given the offset, it should usually set together with limit @@ -141,6 +142,7 @@ Name | Type | Description | Notes **limit** | **Number**| the numbers of flags to return | [optional] **enabled** | **Boolean**| return flags having given enabled status | [optional] **description** | **String**| return flags exactly matching given description | [optional] + **tags** | **String**| return flags with the given tags (comma separated) | [optional] **descriptionLike** | **String**| return flags partially matching given description | [optional] **key** | **String**| return flags matching given key | [optional] **offset** | **Number**| return flags given the offset, it should usually set together with limit | [optional] @@ -205,7 +207,7 @@ No authorization required # **getFlagEntityTypes** -> ['String'] getFlagEntityTypes() +> ['String'] getFlagEntityTypes() @@ -230,7 +232,7 @@ This endpoint does not need any parameter. ### Return type -**['String']** +**['String']** ### Authorization diff --git a/docs/Health.md b/docs/Health.md new file mode 100644 index 0000000..3f4ca6a --- /dev/null +++ b/docs/Health.md @@ -0,0 +1,8 @@ +# Jsflagr.Health + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**status** | **String** | | [optional] + + diff --git a/docs/HealthApi.md b/docs/HealthApi.md index 7edfe3d..beb0449 100644 --- a/docs/HealthApi.md +++ b/docs/HealthApi.md @@ -9,7 +9,7 @@ Method | HTTP request | Description # **getHealth** -> getHealth() +> Health getHealth() @@ -25,7 +25,7 @@ var callback = function(error, data, response) { if (error) { console.error(error); } else { - console.log('API called successfully.'); + console.log('API called successfully. Returned data: ' + data); } }; apiInstance.getHealth(callback); @@ -36,7 +36,7 @@ This endpoint does not need any parameter. ### Return type -null (empty response body) +[**Health**](Health.md) ### Authorization diff --git a/docs/PutFlagRequest.md b/docs/PutFlagRequest.md index e10b93c..1424f07 100644 --- a/docs/PutFlagRequest.md +++ b/docs/PutFlagRequest.md @@ -5,8 +5,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **description** | **String** | | [optional] **dataRecordsEnabled** | **Boolean** | enabled data records will get data logging in the metrics pipeline, for example, kafka. | [optional] -**entityType** | **String** | it will overwrite entityType into evaluation logs if it's not empty | [optional] +**entityType** | **String** | it will overwrite entityType into evaluation logs if it's not empty | [optional] **enabled** | **Boolean** | | [optional] **key** | **String** | | [optional] +**notes** | **String** | | [optional] diff --git a/docs/Tag.md b/docs/Tag.md new file mode 100644 index 0000000..9b8fa51 --- /dev/null +++ b/docs/Tag.md @@ -0,0 +1,9 @@ +# Jsflagr.Tag + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Number** | | [optional] +**value** | **String** | | + + diff --git a/docs/TagApi.md b/docs/TagApi.md new file mode 100644 index 0000000..5f1bee8 --- /dev/null +++ b/docs/TagApi.md @@ -0,0 +1,199 @@ +# Jsflagr.TagApi + +All URIs are relative to *http://localhost/api/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**createTag**](TagApi.md#createTag) | **POST** /flags/{flagID}/tags | +[**deleteTag**](TagApi.md#deleteTag) | **DELETE** /flags/{flagID}/tags/{tagID} | +[**findAllTags**](TagApi.md#findAllTags) | **GET** /tags | +[**findTags**](TagApi.md#findTags) | **GET** /flags/{flagID}/tags | + + + +# **createTag** +> Tag createTag(flagID, body) + + + +### Example +```javascript +var Jsflagr = require('jsflagr'); + +var apiInstance = new Jsflagr.TagApi(); + +var flagID = 789; // Number | numeric ID of the flag + +var body = new Jsflagr.CreateTagRequest(); // CreateTagRequest | create a tag + + +var callback = function(error, data, response) { + if (error) { + console.error(error); + } else { + console.log('API called successfully. Returned data: ' + data); + } +}; +apiInstance.createTag(flagID, body, callback); +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flagID** | **Number**| numeric ID of the flag | + **body** | [**CreateTagRequest**](CreateTagRequest.md)| create a tag | + +### Return type + +[**Tag**](Tag.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **deleteTag** +> deleteTag(flagID, tagID) + + + +### Example +```javascript +var Jsflagr = require('jsflagr'); + +var apiInstance = new Jsflagr.TagApi(); + +var flagID = 789; // Number | numeric ID of the flag + +var tagID = 789; // Number | numeric ID of the tag + + +var callback = function(error, data, response) { + if (error) { + console.error(error); + } else { + console.log('API called successfully.'); + } +}; +apiInstance.deleteTag(flagID, tagID, callback); +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flagID** | **Number**| numeric ID of the flag | + **tagID** | **Number**| numeric ID of the tag | + +### Return type + +null (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **findAllTags** +> [Tag] findAllTags(opts) + + + +### Example +```javascript +var Jsflagr = require('jsflagr'); + +var apiInstance = new Jsflagr.TagApi(); + +var opts = { + 'limit': 789, // Number | the numbers of tags to return + 'offset': 789, // Number | return tags given the offset, it should usually set together with limit + 'valueLike': "valueLike_example" // String | return tags partially matching given value +}; + +var callback = function(error, data, response) { + if (error) { + console.error(error); + } else { + console.log('API called successfully. Returned data: ' + data); + } +}; +apiInstance.findAllTags(opts, callback); +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **limit** | **Number**| the numbers of tags to return | [optional] + **offset** | **Number**| return tags given the offset, it should usually set together with limit | [optional] + **valueLike** | **String**| return tags partially matching given value | [optional] + +### Return type + +[**[Tag]**](Tag.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **findTags** +> [Tag] findTags(flagID) + + + +### Example +```javascript +var Jsflagr = require('jsflagr'); + +var apiInstance = new Jsflagr.TagApi(); + +var flagID = 789; // Number | numeric ID of the flag + + +var callback = function(error, data, response) { + if (error) { + console.error(error); + } else { + console.log('API called successfully. Returned data: ' + data); + } +}; +apiInstance.findTags(flagID, callback); +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flagID** | **Number**| numeric ID of the flag | + +### Return type + +[**[Tag]**](Tag.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + diff --git a/package-lock.json b/package-lock.json index b9889f0..ad22af9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,9 +1,61 @@ { "name": "jsflagr", - "version": "1.0.13", + "version": "1.1.10", "lockfileVersion": 1, "requires": true, "dependencies": { + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", + "dev": true + }, + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, "asynckit": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", @@ -15,6 +67,12 @@ "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", "dev": true }, + "binary-extensions": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", + "dev": true + }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -25,12 +83,119 @@ "concat-map": "0.0.1" } }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, "browser-stdout": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", "dev": true }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true + }, + "chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "dependencies": { + "supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } + } + } + }, + "chokidar": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.1.tgz", + "integrity": "sha512-4QYCEWOcK3OJrxwvyyAOxFuhpvOVCYkr33LPfFNBjAD/w3sEzWsp2BUOkI4l9bHvWioAd0rc6NlHUOEaWkTeqg==", + "dev": true, + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.1.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.3.0" + } + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, "combined-stream": { "version": "1.0.7", "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.7.tgz", @@ -39,12 +204,6 @@ "delayed-stream": "~1.0.0" } }, - "commander": { - "version": "2.15.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz", - "integrity": "sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag==", - "dev": true - }, "component-emitter": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", @@ -74,23 +233,109 @@ "ms": "^2.1.1" } }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "dev": true + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "requires": { + "object-keys": "^1.0.12" + } + }, "delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" }, "diff": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", - "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", + "dev": true, + "requires": { + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" + } + }, + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", "dev": true }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", + "dev": true, + "requires": { + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" + }, + "dependencies": { + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "dev": true + } + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dev": true, + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, "escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", "dev": true }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, "expect.js": { "version": "0.3.1", "resolved": "https://registry.npmjs.org/expect.js/-/expect.js-0.3.1.tgz", @@ -102,6 +347,34 @@ "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==" }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dev": true, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "requires": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + } + }, + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", + "dev": true, + "requires": { + "is-buffer": "~2.0.3" + } + }, "form-data": { "version": "2.3.3", "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", @@ -132,10 +405,29 @@ "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true }, + "fsevents": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", + "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true + }, "glob": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", - "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", "dev": true, "requires": { "fs.realpath": "^1.0.0", @@ -146,22 +438,46 @@ "path-is-absolute": "^1.0.0" } }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "dev": true, + "requires": { + "is-glob": "^4.0.1" + } + }, "growl": { "version": "1.10.5", "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", "dev": true }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "^1.1.1" + } + }, "has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", "dev": true }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", + "dev": true + }, "he": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/he/-/he-1.1.1.tgz", - "integrity": "sha1-k0EP0hsAlzUVH4howvJx80J+I/0=", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", "dev": true }, "inflight": { @@ -179,11 +495,163 @@ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", + "dev": true + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", + "dev": true + }, + "is-callable": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.0.tgz", + "integrity": "sha512-pyVD9AaGLxtg6srb2Ng6ynWJqkHU9bEM087AKck0w8QwDarTfNcpIYoU8x8Hv2Icm8u6kFJM18Dag8lyqGkviw==", + "dev": true + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", + "dev": true + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "dev": true, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==", + "dev": true + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true + }, + "is-regex": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.0.tgz", + "integrity": "sha512-iI97M8KTWID2la5uYXlkbSDQIg4F6o1sYboZKKTDpnDQMLtUL86zxhgDet3Q2SriaYsyGqZ6Mn2SjbRKeLHdqw==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==", + "dev": true + }, + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==", + "dev": true + }, + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, "isarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==", + "dev": true + }, + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", + "dev": true, + "requires": { + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" + } + }, + "js-yaml": { + "version": "3.13.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", + "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "requires": { + "p-locate": "^4.1.0" + } + }, + "lodash": { + "version": "4.17.19", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", + "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "dev": true + }, + "log-symbols": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", + "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", + "dev": true, + "requires": { + "chalk": "^2.4.2" + } + }, "lolex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/lolex/-/lolex-1.3.2.tgz", @@ -222,53 +690,43 @@ "brace-expansion": "^1.1.7" } }, - "minimist": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "dev": true - }, - "mkdirp": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", - "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", - "dev": true, - "requires": { - "minimist": "0.0.8" - } - }, "mocha": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-5.2.0.tgz", - "integrity": "sha512-2IUgKDhc3J7Uug+FxMXuqIyYzH7gJjXECKe/w43IGgQHTSj3InJi+yAA7T24L9bQMRKiUEHxEX37G5JpVUGLcQ==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.0.1.tgz", + "integrity": "sha512-vefaXfdYI8+Yo8nPZQQi0QO2o+5q9UIMX1jZ1XMmK3+4+CQjc7+B0hPdUeglXiTlr8IHMVRo63IhO9Mzt6fxOg==", "dev": true, "requires": { + "ansi-colors": "4.1.1", "browser-stdout": "1.3.1", - "commander": "2.15.1", - "debug": "3.1.0", - "diff": "3.5.0", + "chokidar": "3.3.1", + "debug": "3.2.6", + "diff": "4.0.2", "escape-string-regexp": "1.0.5", - "glob": "7.1.2", + "find-up": "4.1.0", + "glob": "7.1.6", "growl": "1.10.5", - "he": "1.1.1", + "he": "1.2.0", + "js-yaml": "3.13.1", + "log-symbols": "3.0.0", "minimatch": "3.0.4", - "mkdirp": "0.5.1", - "supports-color": "5.4.0" + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "3.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.0" }, "dependencies": { - "debug": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", - "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", "dev": true } } @@ -278,6 +736,36 @@ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==", + "dev": true + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -287,22 +775,76 @@ "wrappy": "1" } }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "requires": { + "p-limit": "^2.2.0" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true + }, "path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", + "dev": true + }, "process-nextick-args": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==" }, + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "dev": true, + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, "qs": { "version": "6.6.0", "resolved": "https://registry.npmjs.org/qs/-/qs-6.6.0.tgz", "integrity": "sha512-KIJqT9jQJDQx5h5uAVPimw6yVg2SekOKu959OCtktD3FjzbpvaPr8i4zzg07DOMz+igA4W/aNM7OV8H37pFYfA==" }, + "querystring": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/querystring/-/querystring-0.2.0.tgz", + "integrity": "sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA=" + }, "readable-stream": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", @@ -317,6 +859,27 @@ "util-deprecate": "~1.0.1" } }, + "readdirp": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.3.0.tgz", + "integrity": "sha512-zz0pAkSPOXXm1viEwygWIPSPkcBYjW1xU5j/JBh5t9bGCJwa6f9+BJa6VaB2g+b55yVrmXzqkyLf4xaWYM0IkQ==", + "dev": true, + "requires": { + "picomatch": "^2.0.7" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, "safe-buffer": { "version": "5.1.2", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", @@ -328,6 +891,18 @@ "integrity": "sha1-vsEf3IOp/aBjQBIQ5AF2wwJNFWc=", "dev": true }, + "serialize-javascript": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-3.0.0.tgz", + "integrity": "sha512-skZcHYw2vEX4bw90nAr2iTTsz6x2SrHEnfxgKYmZlvJYBEZrvbKtobJWlQ20zczKb3bsHHXXTYt48zBA7ni9cw==", + "dev": true + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, "sinon": { "version": "1.17.3", "resolved": "https://registry.npmjs.org/sinon/-/sinon-1.17.3.tgz", @@ -340,6 +915,42 @@ "util": ">=0.10.3 <1" } }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, "string_decoder": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", @@ -348,6 +959,21 @@ "safe-buffer": "~5.1.0" } }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "^3.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==", + "dev": true + }, "superagent": { "version": "3.7.0", "resolved": "https://registry.npmjs.org/superagent/-/superagent-3.7.0.tgz", @@ -366,12 +992,29 @@ } }, "supports-color": { - "version": "5.4.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", - "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", "dev": true, "requires": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" + }, + "dependencies": { + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + } + } + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "requires": { + "is-number": "^7.0.0" } }, "util": { @@ -388,11 +1031,187 @@ "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "dev": true, + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, "wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", + "dev": true + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "yargs-unparser": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.0.tgz", + "integrity": "sha512-W9tKgmSn0DpSatfri0nx52Joq5hVXgeLiqR/5G0sZNDoLZFOr/xjBUDcShCOGNsBnEMNo1KAMBkTej1Hm62HTw==", + "dev": true, + "requires": { + "flat": "^4.1.0", + "lodash": "^4.17.15", + "yargs": "^13.3.0" + } } } } diff --git a/package.json b/package.json index 5827059..dcb1f9e 100644 --- a/package.json +++ b/package.json @@ -1,21 +1,22 @@ { "name": "jsflagr", - "version": "1.1.0", + "version": "1.1.10", "description": "jsflagr is a Javascript client SDK for Flagr.", "license": "Apache 2.0", "main": "src/index.js", "scripts": { - "test": "./node_modules/mocha/bin/mocha --recursive" + "test": "mocha --recursive" }, "browser": { "fs": false }, "dependencies": { - "superagent": "3.7.0" + "superagent": "3.7.0", + "querystring": "0.2.0" }, "devDependencies": { "expect.js": "~0.3.1", - "mocha": "^5.2.0", + "mocha": "^8.0.1", "sinon": "1.17.3" } } diff --git a/src/ApiClient.js b/src/ApiClient.js index b6fd8ba..f5a36c8 100644 --- a/src/ApiClient.js +++ b/src/ApiClient.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -32,7 +32,7 @@ /** * @module ApiClient - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -109,7 +109,7 @@ return ''; } if (param instanceof Date) { - return param.toJSON(); + return param.toISOString(); } return param.toString(); }; @@ -494,12 +494,15 @@ }; /** - * Parses an ISO-8601 string representation of a date value. - * @param {String} str The date value as a string. + * Parses a string representation of a date value. + * @param {String} str The date value as an ISO-8601 full-date or date-time string. * @returns {Date} The parsed date object. */ exports.parseDate = function(str) { - return new Date(str.replace(/T/i, ' ')); + // OpenAPI 2.0 & 3.0 specs state that: + // - date values are serialized as ISO-8601 full-date strings. + // - date-time values are serialized as ISO-8601 date-time strings, in which the timezone offset is mandatory. + return new Date(str); }; /** diff --git a/src/api/ConstraintApi.js b/src/api/ConstraintApi.js index 83f11cc..8a854f4 100644 --- a/src/api/ConstraintApi.js +++ b/src/api/ConstraintApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Constraint service. * @module api/ConstraintApi - * @version 1.1.0 + * @version 1.1.10 */ /** diff --git a/src/api/DistributionApi.js b/src/api/DistributionApi.js index b89c6d6..4c6668f 100644 --- a/src/api/DistributionApi.js +++ b/src/api/DistributionApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Distribution service. * @module api/DistributionApi - * @version 1.1.0 + * @version 1.1.10 */ /** diff --git a/src/api/EvaluationApi.js b/src/api/EvaluationApi.js index 99a1fbe..6883aa1 100644 --- a/src/api/EvaluationApi.js +++ b/src/api/EvaluationApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Evaluation service. * @module api/EvaluationApi - * @version 1.1.0 + * @version 1.1.10 */ /** diff --git a/src/api/ExportApi.js b/src/api/ExportApi.js index 45415cf..f3581cf 100644 --- a/src/api/ExportApi.js +++ b/src/api/ExportApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Export service. * @module api/ExportApi - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,8 +48,48 @@ /** - * Callback function to receive the result of the getExportSQLite operation. - * @callback module:api/ExportApi~getExportSQLiteCallback + * Callback function to receive the result of the getExportEvalCacheJSON operation. + * @callback module:api/ExportApi~getExportEvalCacheJSONCallback + * @param {String} error Error message, if any. + * @param {Object} data The data returned by the service call. + * @param {String} response The complete HTTP response. + */ + + /** + * Export JSON format of the eval cache dump + * @param {module:api/ExportApi~getExportEvalCacheJSONCallback} callback The callback function, accepting three arguments: error, data, response + * data is of type: {@link Object} + */ + this.getExportEvalCacheJSON = function(callback) { + var postBody = null; + + + var pathParams = { + }; + var queryParams = { + }; + var collectionQueryParams = { + }; + var headerParams = { + }; + var formParams = { + }; + + var authNames = []; + var contentTypes = ['application/json']; + var accepts = ['application/json']; + var returnType = Object; + + return this.apiClient.callApi( + '/export/eval_cache/json', 'GET', + pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody, + authNames, contentTypes, accepts, returnType, callback + ); + } + + /** + * Callback function to receive the result of the getExportSqlite operation. + * @callback module:api/ExportApi~getExportSqliteCallback * @param {String} error Error message, if any. * @param {File} data The data returned by the service call. * @param {String} response The complete HTTP response. @@ -57,16 +97,20 @@ /** * Export sqlite3 format of the db dump, which is converted from the main database. - * @param {module:api/ExportApi~getExportSQLiteCallback} callback The callback function, accepting three arguments: error, data, response + * @param {Object} opts Optional parameters + * @param {Boolean} opts.excludeSnapshots export without snapshots data - useful for smaller db without snapshots + * @param {module:api/ExportApi~getExportSqliteCallback} callback The callback function, accepting three arguments: error, data, response * data is of type: {@link File} */ - this.getExportSQLite = function(callback) { + this.getExportSqlite = function(opts, callback) { + opts = opts || {}; var postBody = null; var pathParams = { }; var queryParams = { + 'exclude_snapshots': opts['excludeSnapshots'], }; var collectionQueryParams = { }; diff --git a/src/api/FlagApi.js b/src/api/FlagApi.js index efce232..6b42474 100644 --- a/src/api/FlagApi.js +++ b/src/api/FlagApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Flag service. * @module api/FlagApi - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -150,6 +150,7 @@ * @param {Number} opts.limit the numbers of flags to return * @param {Boolean} opts.enabled return flags having given enabled status * @param {String} opts.description return flags exactly matching given description + * @param {String} opts.tags return flags with the given tags (comma separated) * @param {String} opts.descriptionLike return flags partially matching given description * @param {String} opts.key return flags matching given key * @param {Number} opts.offset return flags given the offset, it should usually set together with limit @@ -168,6 +169,7 @@ 'limit': opts['limit'], 'enabled': opts['enabled'], 'description': opts['description'], + 'tags': opts['tags'], 'description_like': opts['descriptionLike'], 'key': opts['key'], 'offset': opts['offset'], diff --git a/src/api/HealthApi.js b/src/api/HealthApi.js index 7c23b95..7f1ac68 100644 --- a/src/api/HealthApi.js +++ b/src/api/HealthApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -16,24 +16,24 @@ (function(root, factory) { if (typeof define === 'function' && define.amd) { // AMD. Register as an anonymous module. - define(['ApiClient', 'model/Error'], factory); + define(['ApiClient', 'model/Error', 'model/Health'], factory); } else if (typeof module === 'object' && module.exports) { // CommonJS-like environments that support module.exports, like Node. - module.exports = factory(require('../ApiClient'), require('../model/Error')); + module.exports = factory(require('../ApiClient'), require('../model/Error'), require('../model/Health')); } else { // Browser globals (root is window) if (!root.Jsflagr) { root.Jsflagr = {}; } - root.Jsflagr.HealthApi = factory(root.Jsflagr.ApiClient, root.Jsflagr.Error); + root.Jsflagr.HealthApi = factory(root.Jsflagr.ApiClient, root.Jsflagr.Error, root.Jsflagr.Health); } -}(this, function(ApiClient, Error) { +}(this, function(ApiClient, Error, Health) { 'use strict'; /** * Health service. * @module api/HealthApi - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -51,13 +51,14 @@ * Callback function to receive the result of the getHealth operation. * @callback module:api/HealthApi~getHealthCallback * @param {String} error Error message, if any. - * @param data This operation does not return a value. + * @param {module:model/Health} data The data returned by the service call. * @param {String} response The complete HTTP response. */ /** * Check if Flagr is healthy * @param {module:api/HealthApi~getHealthCallback} callback The callback function, accepting three arguments: error, data, response + * data is of type: {@link module:model/Health} */ this.getHealth = function(callback) { var postBody = null; @@ -77,7 +78,7 @@ var authNames = []; var contentTypes = ['application/json']; var accepts = ['application/json']; - var returnType = null; + var returnType = Health; return this.apiClient.callApi( '/health', 'GET', diff --git a/src/api/SegmentApi.js b/src/api/SegmentApi.js index 32a4893..94e379c 100644 --- a/src/api/SegmentApi.js +++ b/src/api/SegmentApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Segment service. * @module api/SegmentApi - * @version 1.1.0 + * @version 1.1.10 */ /** diff --git a/src/api/TagApi.js b/src/api/TagApi.js new file mode 100644 index 0000000..14ddcd1 --- /dev/null +++ b/src/api/TagApi.js @@ -0,0 +1,249 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. Register as an anonymous module. + define(['ApiClient', 'model/CreateTagRequest', 'model/Error', 'model/Tag'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + module.exports = factory(require('../ApiClient'), require('../model/CreateTagRequest'), require('../model/Error'), require('../model/Tag')); + } else { + // Browser globals (root is window) + if (!root.Jsflagr) { + root.Jsflagr = {}; + } + root.Jsflagr.TagApi = factory(root.Jsflagr.ApiClient, root.Jsflagr.CreateTagRequest, root.Jsflagr.Error, root.Jsflagr.Tag); + } +}(this, function(ApiClient, CreateTagRequest, Error, Tag) { + 'use strict'; + + /** + * Tag service. + * @module api/TagApi + * @version 1.1.10 + */ + + /** + * Constructs a new TagApi. + * @alias module:api/TagApi + * @class + * @param {module:ApiClient} [apiClient] Optional API client implementation to use, + * default to {@link module:ApiClient#instance} if unspecified. + */ + var exports = function(apiClient) { + this.apiClient = apiClient || ApiClient.instance; + + + /** + * Callback function to receive the result of the createTag operation. + * @callback module:api/TagApi~createTagCallback + * @param {String} error Error message, if any. + * @param {module:model/Tag} data The data returned by the service call. + * @param {String} response The complete HTTP response. + */ + + /** + * @param {Number} flagID numeric ID of the flag + * @param {module:model/CreateTagRequest} body create a tag + * @param {module:api/TagApi~createTagCallback} callback The callback function, accepting three arguments: error, data, response + * data is of type: {@link module:model/Tag} + */ + this.createTag = function(flagID, body, callback) { + var postBody = body; + + // verify the required parameter 'flagID' is set + if (flagID === undefined || flagID === null) { + throw new Error("Missing the required parameter 'flagID' when calling createTag"); + } + + // verify the required parameter 'body' is set + if (body === undefined || body === null) { + throw new Error("Missing the required parameter 'body' when calling createTag"); + } + + + var pathParams = { + 'flagID': flagID + }; + var queryParams = { + }; + var collectionQueryParams = { + }; + var headerParams = { + }; + var formParams = { + }; + + var authNames = []; + var contentTypes = ['application/json']; + var accepts = ['application/json']; + var returnType = Tag; + + return this.apiClient.callApi( + '/flags/{flagID}/tags', 'POST', + pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody, + authNames, contentTypes, accepts, returnType, callback + ); + } + + /** + * Callback function to receive the result of the deleteTag operation. + * @callback module:api/TagApi~deleteTagCallback + * @param {String} error Error message, if any. + * @param data This operation does not return a value. + * @param {String} response The complete HTTP response. + */ + + /** + * @param {Number} flagID numeric ID of the flag + * @param {Number} tagID numeric ID of the tag + * @param {module:api/TagApi~deleteTagCallback} callback The callback function, accepting three arguments: error, data, response + */ + this.deleteTag = function(flagID, tagID, callback) { + var postBody = null; + + // verify the required parameter 'flagID' is set + if (flagID === undefined || flagID === null) { + throw new Error("Missing the required parameter 'flagID' when calling deleteTag"); + } + + // verify the required parameter 'tagID' is set + if (tagID === undefined || tagID === null) { + throw new Error("Missing the required parameter 'tagID' when calling deleteTag"); + } + + + var pathParams = { + 'flagID': flagID, + 'tagID': tagID + }; + var queryParams = { + }; + var collectionQueryParams = { + }; + var headerParams = { + }; + var formParams = { + }; + + var authNames = []; + var contentTypes = ['application/json']; + var accepts = ['application/json']; + var returnType = null; + + return this.apiClient.callApi( + '/flags/{flagID}/tags/{tagID}', 'DELETE', + pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody, + authNames, contentTypes, accepts, returnType, callback + ); + } + + /** + * Callback function to receive the result of the findAllTags operation. + * @callback module:api/TagApi~findAllTagsCallback + * @param {String} error Error message, if any. + * @param {Array.} data The data returned by the service call. + * @param {String} response The complete HTTP response. + */ + + /** + * @param {Object} opts Optional parameters + * @param {Number} opts.limit the numbers of tags to return + * @param {Number} opts.offset return tags given the offset, it should usually set together with limit + * @param {String} opts.valueLike return tags partially matching given value + * @param {module:api/TagApi~findAllTagsCallback} callback The callback function, accepting three arguments: error, data, response + * data is of type: {@link Array.} + */ + this.findAllTags = function(opts, callback) { + opts = opts || {}; + var postBody = null; + + + var pathParams = { + }; + var queryParams = { + 'limit': opts['limit'], + 'offset': opts['offset'], + 'value_like': opts['valueLike'], + }; + var collectionQueryParams = { + }; + var headerParams = { + }; + var formParams = { + }; + + var authNames = []; + var contentTypes = ['application/json']; + var accepts = ['application/json']; + var returnType = [Tag]; + + return this.apiClient.callApi( + '/tags', 'GET', + pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody, + authNames, contentTypes, accepts, returnType, callback + ); + } + + /** + * Callback function to receive the result of the findTags operation. + * @callback module:api/TagApi~findTagsCallback + * @param {String} error Error message, if any. + * @param {Array.} data The data returned by the service call. + * @param {String} response The complete HTTP response. + */ + + /** + * @param {Number} flagID numeric ID of the flag + * @param {module:api/TagApi~findTagsCallback} callback The callback function, accepting three arguments: error, data, response + * data is of type: {@link Array.} + */ + this.findTags = function(flagID, callback) { + var postBody = null; + + // verify the required parameter 'flagID' is set + if (flagID === undefined || flagID === null) { + throw new Error("Missing the required parameter 'flagID' when calling findTags"); + } + + + var pathParams = { + 'flagID': flagID + }; + var queryParams = { + }; + var collectionQueryParams = { + }; + var headerParams = { + }; + var formParams = { + }; + + var authNames = []; + var contentTypes = ['application/json']; + var accepts = ['application/json']; + var returnType = [Tag]; + + return this.apiClient.callApi( + '/flags/{flagID}/tags', 'GET', + pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody, + authNames, contentTypes, accepts, returnType, callback + ); + } + }; + + return exports; +})); diff --git a/src/api/VariantApi.js b/src/api/VariantApi.js index ee886bf..6a26da0 100644 --- a/src/api/VariantApi.js +++ b/src/api/VariantApi.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,7 +33,7 @@ /** * Variant service. * @module api/VariantApi - * @version 1.1.0 + * @version 1.1.10 */ /** diff --git a/src/index.js b/src/index.js index 4f8a53d..fc8b873 100644 --- a/src/index.js +++ b/src/index.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -16,12 +16,12 @@ (function(factory) { if (typeof define === 'function' && define.amd) { // AMD. Register as an anonymous module. - define(['ApiClient', 'model/Constraint', 'model/CreateConstraintRequest', 'model/CreateFlagRequest', 'model/CreateSegmentRequest', 'model/CreateVariantRequest', 'model/Distribution', 'model/Error', 'model/EvalContext', 'model/EvalDebugLog', 'model/EvalResult', 'model/EvaluationBatchRequest', 'model/EvaluationBatchResponse', 'model/EvaluationEntity', 'model/Flag', 'model/FlagSnapshot', 'model/PutDistributionsRequest', 'model/PutFlagRequest', 'model/PutSegmentReorderRequest', 'model/PutSegmentRequest', 'model/PutVariantRequest', 'model/Segment', 'model/SegmentDebugLog', 'model/SetFlagEnabledRequest', 'model/Variant', 'api/ConstraintApi', 'api/DistributionApi', 'api/EvaluationApi', 'api/ExportApi', 'api/FlagApi', 'api/HealthApi', 'api/SegmentApi', 'api/VariantApi'], factory); + define(['ApiClient', 'model/Constraint', 'model/CreateConstraintRequest', 'model/CreateFlagRequest', 'model/CreateSegmentRequest', 'model/CreateTagRequest', 'model/CreateVariantRequest', 'model/Distribution', 'model/Error', 'model/EvalContext', 'model/EvalDebugLog', 'model/EvalResult', 'model/EvaluationBatchRequest', 'model/EvaluationBatchResponse', 'model/EvaluationEntity', 'model/Flag', 'model/FlagSnapshot', 'model/Health', 'model/PutDistributionsRequest', 'model/PutFlagRequest', 'model/PutSegmentReorderRequest', 'model/PutSegmentRequest', 'model/PutVariantRequest', 'model/Segment', 'model/SegmentDebugLog', 'model/SetFlagEnabledRequest', 'model/Tag', 'model/Variant', 'api/ConstraintApi', 'api/DistributionApi', 'api/EvaluationApi', 'api/ExportApi', 'api/FlagApi', 'api/HealthApi', 'api/SegmentApi', 'api/TagApi', 'api/VariantApi'], factory); } else if (typeof module === 'object' && module.exports) { // CommonJS-like environments that support module.exports, like Node. - module.exports = factory(require('./ApiClient'), require('./model/Constraint'), require('./model/CreateConstraintRequest'), require('./model/CreateFlagRequest'), require('./model/CreateSegmentRequest'), require('./model/CreateVariantRequest'), require('./model/Distribution'), require('./model/Error'), require('./model/EvalContext'), require('./model/EvalDebugLog'), require('./model/EvalResult'), require('./model/EvaluationBatchRequest'), require('./model/EvaluationBatchResponse'), require('./model/EvaluationEntity'), require('./model/Flag'), require('./model/FlagSnapshot'), require('./model/PutDistributionsRequest'), require('./model/PutFlagRequest'), require('./model/PutSegmentReorderRequest'), require('./model/PutSegmentRequest'), require('./model/PutVariantRequest'), require('./model/Segment'), require('./model/SegmentDebugLog'), require('./model/SetFlagEnabledRequest'), require('./model/Variant'), require('./api/ConstraintApi'), require('./api/DistributionApi'), require('./api/EvaluationApi'), require('./api/ExportApi'), require('./api/FlagApi'), require('./api/HealthApi'), require('./api/SegmentApi'), require('./api/VariantApi')); + module.exports = factory(require('./ApiClient'), require('./model/Constraint'), require('./model/CreateConstraintRequest'), require('./model/CreateFlagRequest'), require('./model/CreateSegmentRequest'), require('./model/CreateTagRequest'), require('./model/CreateVariantRequest'), require('./model/Distribution'), require('./model/Error'), require('./model/EvalContext'), require('./model/EvalDebugLog'), require('./model/EvalResult'), require('./model/EvaluationBatchRequest'), require('./model/EvaluationBatchResponse'), require('./model/EvaluationEntity'), require('./model/Flag'), require('./model/FlagSnapshot'), require('./model/Health'), require('./model/PutDistributionsRequest'), require('./model/PutFlagRequest'), require('./model/PutSegmentReorderRequest'), require('./model/PutSegmentRequest'), require('./model/PutVariantRequest'), require('./model/Segment'), require('./model/SegmentDebugLog'), require('./model/SetFlagEnabledRequest'), require('./model/Tag'), require('./model/Variant'), require('./api/ConstraintApi'), require('./api/DistributionApi'), require('./api/EvaluationApi'), require('./api/ExportApi'), require('./api/FlagApi'), require('./api/HealthApi'), require('./api/SegmentApi'), require('./api/TagApi'), require('./api/VariantApi')); } -}(function(ApiClient, Constraint, CreateConstraintRequest, CreateFlagRequest, CreateSegmentRequest, CreateVariantRequest, Distribution, Error, EvalContext, EvalDebugLog, EvalResult, EvaluationBatchRequest, EvaluationBatchResponse, EvaluationEntity, Flag, FlagSnapshot, PutDistributionsRequest, PutFlagRequest, PutSegmentReorderRequest, PutSegmentRequest, PutVariantRequest, Segment, SegmentDebugLog, SetFlagEnabledRequest, Variant, ConstraintApi, DistributionApi, EvaluationApi, ExportApi, FlagApi, HealthApi, SegmentApi, VariantApi) { +}(function(ApiClient, Constraint, CreateConstraintRequest, CreateFlagRequest, CreateSegmentRequest, CreateTagRequest, CreateVariantRequest, Distribution, Error, EvalContext, EvalDebugLog, EvalResult, EvaluationBatchRequest, EvaluationBatchResponse, EvaluationEntity, Flag, FlagSnapshot, Health, PutDistributionsRequest, PutFlagRequest, PutSegmentReorderRequest, PutSegmentRequest, PutVariantRequest, Segment, SegmentDebugLog, SetFlagEnabledRequest, Tag, Variant, ConstraintApi, DistributionApi, EvaluationApi, ExportApi, FlagApi, HealthApi, SegmentApi, TagApi, VariantApi) { 'use strict'; /** @@ -53,7 +53,7 @@ * *

* @module index - * @version 1.1.0 + * @version 1.1.10 */ var exports = { /** @@ -81,6 +81,11 @@ * @property {module:model/CreateSegmentRequest} */ CreateSegmentRequest: CreateSegmentRequest, + /** + * The CreateTagRequest model constructor. + * @property {module:model/CreateTagRequest} + */ + CreateTagRequest: CreateTagRequest, /** * The CreateVariantRequest model constructor. * @property {module:model/CreateVariantRequest} @@ -136,6 +141,11 @@ * @property {module:model/FlagSnapshot} */ FlagSnapshot: FlagSnapshot, + /** + * The Health model constructor. + * @property {module:model/Health} + */ + Health: Health, /** * The PutDistributionsRequest model constructor. * @property {module:model/PutDistributionsRequest} @@ -176,6 +186,11 @@ * @property {module:model/SetFlagEnabledRequest} */ SetFlagEnabledRequest: SetFlagEnabledRequest, + /** + * The Tag model constructor. + * @property {module:model/Tag} + */ + Tag: Tag, /** * The Variant model constructor. * @property {module:model/Variant} @@ -216,6 +231,11 @@ * @property {module:api/SegmentApi} */ SegmentApi: SegmentApi, + /** + * The TagApi service constructor. + * @property {module:api/TagApi} + */ + TagApi: TagApi, /** * The VariantApi service constructor. * @property {module:api/VariantApi} diff --git a/src/model/Constraint.js b/src/model/Constraint.js index 55a88c1..790d216 100644 --- a/src/model/Constraint.js +++ b/src/model/Constraint.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The Constraint model module. * @module model/Constraint - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,12 +45,9 @@ * @param value {String} */ var exports = function(property, operator, value) { - var _this = this; - - - _this['property'] = property; - _this['operator'] = operator; - _this['value'] = value; + this.property = property; + this.operator = operator; + this.value = value; }; /** @@ -66,19 +60,14 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('id')) { - obj['id'] = ApiClient.convertToType(data['id'], 'Number'); - } - if (data.hasOwnProperty('property')) { - obj['property'] = ApiClient.convertToType(data['property'], 'String'); - } - if (data.hasOwnProperty('operator')) { - obj['operator'] = ApiClient.convertToType(data['operator'], 'String'); - } - if (data.hasOwnProperty('value')) { - obj['value'] = ApiClient.convertToType(data['value'], 'String'); - } + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('property')) + obj.property = ApiClient.convertToType(data['property'], 'String'); + if (data.hasOwnProperty('operator')) + obj.operator = ApiClient.convertToType(data['operator'], 'String'); + if (data.hasOwnProperty('value')) + obj.value = ApiClient.convertToType(data['value'], 'String'); } return obj; } @@ -86,19 +75,22 @@ /** * @member {Number} id */ - exports.prototype['id'] = undefined; + exports.prototype.id = undefined; + /** * @member {String} property */ - exports.prototype['property'] = undefined; + exports.prototype.property = undefined; + /** * @member {module:model/Constraint.OperatorEnum} operator */ - exports.prototype['operator'] = undefined; + exports.prototype.operator = undefined; + /** * @member {String} value */ - exports.prototype['value'] = undefined; + exports.prototype.value = undefined; /** @@ -111,65 +103,75 @@ * value: "EQ" * @const */ - "EQ": "EQ", + EQ: "EQ", + /** * value: "NEQ" * @const */ - "NEQ": "NEQ", + NEQ: "NEQ", + /** * value: "LT" * @const */ - "LT": "LT", + LT: "LT", + /** * value: "LTE" * @const */ - "LTE": "LTE", + LTE: "LTE", + /** * value: "GT" * @const */ - "GT": "GT", + GT: "GT", + /** * value: "GTE" * @const */ - "GTE": "GTE", + GTE: "GTE", + /** * value: "EREG" * @const */ - "EREG": "EREG", + EREG: "EREG", + /** * value: "NEREG" * @const */ - "NEREG": "NEREG", + NEREG: "NEREG", + /** * value: "IN" * @const */ - "IN": "IN", + IN: "IN", + /** * value: "NOTIN" * @const */ - "NOTIN": "NOTIN", + NOTIN: "NOTIN", + /** * value: "CONTAINS" * @const */ - "CONTAINS": "CONTAINS", + CONTAINS: "CONTAINS", + /** * value: "NOTCONTAINS" * @const */ - "NOTCONTAINS": "NOTCONTAINS" }; - + NOTCONTAINS: "NOTCONTAINS" + }; return exports; -})); - +})); diff --git a/src/model/CreateConstraintRequest.js b/src/model/CreateConstraintRequest.js index d6cdaaa..ef3fd8b 100644 --- a/src/model/CreateConstraintRequest.js +++ b/src/model/CreateConstraintRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The CreateConstraintRequest model module. * @module model/CreateConstraintRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,11 +45,9 @@ * @param value {String} */ var exports = function(property, operator, value) { - var _this = this; - - _this['property'] = property; - _this['operator'] = operator; - _this['value'] = value; + this.property = property; + this.operator = operator; + this.value = value; }; /** @@ -65,16 +60,12 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('property')) { - obj['property'] = ApiClient.convertToType(data['property'], 'String'); - } - if (data.hasOwnProperty('operator')) { - obj['operator'] = ApiClient.convertToType(data['operator'], 'String'); - } - if (data.hasOwnProperty('value')) { - obj['value'] = ApiClient.convertToType(data['value'], 'String'); - } + if (data.hasOwnProperty('property')) + obj.property = ApiClient.convertToType(data['property'], 'String'); + if (data.hasOwnProperty('operator')) + obj.operator = ApiClient.convertToType(data['operator'], 'String'); + if (data.hasOwnProperty('value')) + obj.value = ApiClient.convertToType(data['value'], 'String'); } return obj; } @@ -82,19 +73,18 @@ /** * @member {String} property */ - exports.prototype['property'] = undefined; + exports.prototype.property = undefined; + /** * @member {String} operator */ - exports.prototype['operator'] = undefined; + exports.prototype.operator = undefined; + /** * @member {String} value */ - exports.prototype['value'] = undefined; - - + exports.prototype.value = undefined; return exports; -})); - +})); diff --git a/src/model/CreateFlagRequest.js b/src/model/CreateFlagRequest.js index 5560787..7059674 100644 --- a/src/model/CreateFlagRequest.js +++ b/src/model/CreateFlagRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The CreateFlagRequest model module. * @module model/CreateFlagRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,10 +43,7 @@ * @param description {String} */ var exports = function(description) { - var _this = this; - - _this['description'] = description; - + this.description = description; }; /** @@ -62,13 +56,12 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('description')) { - obj['description'] = ApiClient.convertToType(data['description'], 'String'); - } - if (data.hasOwnProperty('key')) { - obj['key'] = ApiClient.convertToType(data['key'], 'String'); - } + if (data.hasOwnProperty('description')) + obj.description = ApiClient.convertToType(data['description'], 'String'); + if (data.hasOwnProperty('key')) + obj.key = ApiClient.convertToType(data['key'], 'String'); + if (data.hasOwnProperty('template')) + obj.template = ApiClient.convertToType(data['template'], 'String'); } return obj; } @@ -76,16 +69,20 @@ /** * @member {String} description */ - exports.prototype['description'] = undefined; + exports.prototype.description = undefined; + /** * unique key representation of the flag * @member {String} key */ - exports.prototype['key'] = undefined; - + exports.prototype.key = undefined; + /** + * template for flag creation + * @member {String} template + */ + exports.prototype.template = undefined; return exports; -})); - +})); diff --git a/src/model/CreateSegmentRequest.js b/src/model/CreateSegmentRequest.js index 07b6c54..cd6704f 100644 --- a/src/model/CreateSegmentRequest.js +++ b/src/model/CreateSegmentRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The CreateSegmentRequest model module. * @module model/CreateSegmentRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -47,10 +44,8 @@ * @param rolloutPercent {Number} */ var exports = function(description, rolloutPercent) { - var _this = this; - - _this['description'] = description; - _this['rolloutPercent'] = rolloutPercent; + this.description = description; + this.rolloutPercent = rolloutPercent; }; /** @@ -63,13 +58,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('description')) { - obj['description'] = ApiClient.convertToType(data['description'], 'String'); - } - if (data.hasOwnProperty('rolloutPercent')) { - obj['rolloutPercent'] = ApiClient.convertToType(data['rolloutPercent'], 'Number'); - } + if (data.hasOwnProperty('description')) + obj.description = ApiClient.convertToType(data['description'], 'String'); + if (data.hasOwnProperty('rolloutPercent')) + obj.rolloutPercent = ApiClient.convertToType(data['rolloutPercent'], 'Number'); } return obj; } @@ -77,15 +69,13 @@ /** * @member {String} description */ - exports.prototype['description'] = undefined; + exports.prototype.description = undefined; + /** * @member {Number} rolloutPercent */ - exports.prototype['rolloutPercent'] = undefined; - - + exports.prototype.rolloutPercent = undefined; return exports; -})); - +})); diff --git a/src/model/CreateTagRequest.js b/src/model/CreateTagRequest.js new file mode 100644 index 0000000..c6d71d9 --- /dev/null +++ b/src/model/CreateTagRequest.js @@ -0,0 +1,72 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. Register as an anonymous module. + define(['ApiClient'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + module.exports = factory(require('../ApiClient')); + } else { + // Browser globals (root is window) + if (!root.Jsflagr) { + root.Jsflagr = {}; + } + root.Jsflagr.CreateTagRequest = factory(root.Jsflagr.ApiClient); + } +}(this, function(ApiClient) { + 'use strict'; + + /** + * The CreateTagRequest model module. + * @module model/CreateTagRequest + * @version 1.1.10 + */ + + /** + * Constructs a new CreateTagRequest. + * @alias module:model/CreateTagRequest + * @class + * @param value {String} + */ + var exports = function(value) { + this.value = value; + }; + + /** + * Constructs a CreateTagRequest from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/CreateTagRequest} obj Optional instance to populate. + * @return {module:model/CreateTagRequest} The populated CreateTagRequest instance. + */ + exports.constructFromObject = function(data, obj) { + if (data) { + obj = obj || new exports(); + if (data.hasOwnProperty('value')) + obj.value = ApiClient.convertToType(data['value'], 'String'); + } + return obj; + } + + /** + * @member {String} value + */ + exports.prototype.value = undefined; + + return exports; + +})); diff --git a/src/model/CreateVariantRequest.js b/src/model/CreateVariantRequest.js index 71ea382..267f13a 100644 --- a/src/model/CreateVariantRequest.js +++ b/src/model/CreateVariantRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The CreateVariantRequest model module. * @module model/CreateVariantRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,10 +43,7 @@ * @param key {String} */ var exports = function(key) { - var _this = this; - - _this['key'] = key; - + this.key = key; }; /** @@ -62,13 +56,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('key')) { - obj['key'] = ApiClient.convertToType(data['key'], 'String'); - } - if (data.hasOwnProperty('attachment')) { - obj['attachment'] = ApiClient.convertToType(data['attachment'], Object); - } + if (data.hasOwnProperty('key')) + obj.key = ApiClient.convertToType(data['key'], 'String'); + if (data.hasOwnProperty('attachment')) + obj.attachment = ApiClient.convertToType(data['attachment'], Object); } return obj; } @@ -76,15 +67,13 @@ /** * @member {String} key */ - exports.prototype['key'] = undefined; + exports.prototype.key = undefined; + /** * @member {Object} attachment */ - exports.prototype['attachment'] = undefined; - - + exports.prototype.attachment = undefined; return exports; -})); - +})); diff --git a/src/model/Distribution.js b/src/model/Distribution.js index 3371a9c..7af42c8 100644 --- a/src/model/Distribution.js +++ b/src/model/Distribution.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The Distribution model module. * @module model/Distribution - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,12 +45,9 @@ * @param variantID {Number} */ var exports = function(percent, variantKey, variantID) { - var _this = this; - - - _this['percent'] = percent; - _this['variantKey'] = variantKey; - _this['variantID'] = variantID; + this.percent = percent; + this.variantKey = variantKey; + this.variantID = variantID; }; /** @@ -66,19 +60,14 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('id')) { - obj['id'] = ApiClient.convertToType(data['id'], 'Number'); - } - if (data.hasOwnProperty('percent')) { - obj['percent'] = ApiClient.convertToType(data['percent'], 'Number'); - } - if (data.hasOwnProperty('variantKey')) { - obj['variantKey'] = ApiClient.convertToType(data['variantKey'], 'String'); - } - if (data.hasOwnProperty('variantID')) { - obj['variantID'] = ApiClient.convertToType(data['variantID'], 'Number'); - } + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('percent')) + obj.percent = ApiClient.convertToType(data['percent'], 'Number'); + if (data.hasOwnProperty('variantKey')) + obj.variantKey = ApiClient.convertToType(data['variantKey'], 'String'); + if (data.hasOwnProperty('variantID')) + obj.variantID = ApiClient.convertToType(data['variantID'], 'Number'); } return obj; } @@ -86,23 +75,23 @@ /** * @member {Number} id */ - exports.prototype['id'] = undefined; + exports.prototype.id = undefined; + /** * @member {Number} percent */ - exports.prototype['percent'] = undefined; + exports.prototype.percent = undefined; + /** * @member {String} variantKey */ - exports.prototype['variantKey'] = undefined; + exports.prototype.variantKey = undefined; + /** * @member {Number} variantID */ - exports.prototype['variantID'] = undefined; - - + exports.prototype.variantID = undefined; return exports; -})); - +})); diff --git a/src/model/Error.js b/src/model/Error.js index 057d029..2d22910 100644 --- a/src/model/Error.js +++ b/src/model/Error.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The Error model module. * @module model/Error - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,9 +43,7 @@ * @param message {String} */ var exports = function(message) { - var _this = this; - - _this['message'] = message; + this.message = message; }; /** @@ -61,10 +56,8 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('message')) { - obj['message'] = ApiClient.convertToType(data['message'], 'String'); - } + if (data.hasOwnProperty('message')) + obj.message = ApiClient.convertToType(data['message'], 'String'); } return obj; } @@ -72,11 +65,8 @@ /** * @member {String} message */ - exports.prototype['message'] = undefined; - - + exports.prototype.message = undefined; return exports; -})); - +})); diff --git a/src/model/EvalContext.js b/src/model/EvalContext.js index ca8e313..28c4453 100644 --- a/src/model/EvalContext.js +++ b/src/model/EvalContext.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The EvalContext model module. * @module model/EvalContext - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -45,14 +42,6 @@ * @class */ var exports = function() { - var _this = this; - - - - - - - }; /** @@ -65,25 +54,20 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('entityID')) { - obj['entityID'] = ApiClient.convertToType(data['entityID'], 'String'); - } - if (data.hasOwnProperty('entityType')) { - obj['entityType'] = ApiClient.convertToType(data['entityType'], 'String'); - } - if (data.hasOwnProperty('entityContext')) { - obj['entityContext'] = ApiClient.convertToType(data['entityContext'], Object); - } - if (data.hasOwnProperty('enableDebug')) { - obj['enableDebug'] = ApiClient.convertToType(data['enableDebug'], 'Boolean'); - } - if (data.hasOwnProperty('flagID')) { - obj['flagID'] = ApiClient.convertToType(data['flagID'], 'Number'); - } - if (data.hasOwnProperty('flagKey')) { - obj['flagKey'] = ApiClient.convertToType(data['flagKey'], 'String'); - } + if (data.hasOwnProperty('entityID')) + obj.entityID = ApiClient.convertToType(data['entityID'], 'String'); + if (data.hasOwnProperty('entityType')) + obj.entityType = ApiClient.convertToType(data['entityType'], 'String'); + if (data.hasOwnProperty('entityContext')) + obj.entityContext = ApiClient.convertToType(data['entityContext'], Object); + if (data.hasOwnProperty('enableDebug')) + obj.enableDebug = ApiClient.convertToType(data['enableDebug'], 'Boolean'); + if (data.hasOwnProperty('flagID')) + obj.flagID = ApiClient.convertToType(data['flagID'], 'Number'); + if (data.hasOwnProperty('flagKey')) + obj.flagKey = ApiClient.convertToType(data['flagKey'], 'String'); + if (data.hasOwnProperty('flagTags')) + obj.flagTags = ApiClient.convertToType(data['flagTags'], ['String']); } return obj; } @@ -92,33 +76,41 @@ * entityID is used to deterministically at random to evaluate the flag result. If it's empty, flagr will randomly generate one. * @member {String} entityID */ - exports.prototype['entityID'] = undefined; + exports.prototype.entityID = undefined; + /** * @member {String} entityType */ - exports.prototype['entityType'] = undefined; + exports.prototype.entityType = undefined; + /** * @member {Object} entityContext */ - exports.prototype['entityContext'] = undefined; + exports.prototype.entityContext = undefined; + /** * @member {Boolean} enableDebug */ - exports.prototype['enableDebug'] = undefined; + exports.prototype.enableDebug = undefined; + /** * flagID * @member {Number} flagID */ - exports.prototype['flagID'] = undefined; + exports.prototype.flagID = undefined; + /** * flagKey. flagID or flagKey will resolve to the same flag. Either works. * @member {String} flagKey */ - exports.prototype['flagKey'] = undefined; - + exports.prototype.flagKey = undefined; + /** + * flagTags. flagTags looks up flags by tag. Either works. + * @member {Array.} flagTags + */ + exports.prototype.flagTags = undefined; return exports; -})); - +})); diff --git a/src/model/EvalDebugLog.js b/src/model/EvalDebugLog.js index 60994c9..cd744ce 100644 --- a/src/model/EvalDebugLog.js +++ b/src/model/EvalDebugLog.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, SegmentDebugLog) { 'use strict'; - - - /** * The EvalDebugLog model module. * @module model/EvalDebugLog - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -45,10 +42,6 @@ * @class */ var exports = function() { - var _this = this; - - - }; /** @@ -61,13 +54,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('segmentDebugLogs')) { - obj['segmentDebugLogs'] = ApiClient.convertToType(data['segmentDebugLogs'], [SegmentDebugLog]); - } - if (data.hasOwnProperty('msg')) { - obj['msg'] = ApiClient.convertToType(data['msg'], 'String'); - } + if (data.hasOwnProperty('segmentDebugLogs')) + obj.segmentDebugLogs = ApiClient.convertToType(data['segmentDebugLogs'], [SegmentDebugLog]); + if (data.hasOwnProperty('msg')) + obj.msg = ApiClient.convertToType(data['msg'], 'String'); } return obj; } @@ -75,15 +65,13 @@ /** * @member {Array.} segmentDebugLogs */ - exports.prototype['segmentDebugLogs'] = undefined; + exports.prototype.segmentDebugLogs = undefined; + /** * @member {String} msg */ - exports.prototype['msg'] = undefined; - - + exports.prototype.msg = undefined; return exports; -})); - +})); diff --git a/src/model/EvalResult.js b/src/model/EvalResult.js index 192320c..c8de38e 100644 --- a/src/model/EvalResult.js +++ b/src/model/EvalResult.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, EvalContext, EvalDebugLog) { 'use strict'; - - - /** * The EvalResult model module. * @module model/EvalResult - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -45,18 +42,6 @@ * @class */ var exports = function() { - var _this = this; - - - - - - - - - - - }; /** @@ -69,37 +54,26 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('flagID')) { - obj['flagID'] = ApiClient.convertToType(data['flagID'], 'Number'); - } - if (data.hasOwnProperty('flagKey')) { - obj['flagKey'] = ApiClient.convertToType(data['flagKey'], 'String'); - } - if (data.hasOwnProperty('flagSnapshotID')) { - obj['flagSnapshotID'] = ApiClient.convertToType(data['flagSnapshotID'], 'Number'); - } - if (data.hasOwnProperty('segmentID')) { - obj['segmentID'] = ApiClient.convertToType(data['segmentID'], 'Number'); - } - if (data.hasOwnProperty('variantID')) { - obj['variantID'] = ApiClient.convertToType(data['variantID'], 'Number'); - } - if (data.hasOwnProperty('variantKey')) { - obj['variantKey'] = ApiClient.convertToType(data['variantKey'], 'String'); - } - if (data.hasOwnProperty('variantAttachment')) { - obj['variantAttachment'] = ApiClient.convertToType(data['variantAttachment'], Object); - } - if (data.hasOwnProperty('evalContext')) { - obj['evalContext'] = EvalContext.constructFromObject(data['evalContext']); - } - if (data.hasOwnProperty('timestamp')) { - obj['timestamp'] = ApiClient.convertToType(data['timestamp'], 'String'); - } - if (data.hasOwnProperty('evalDebugLog')) { - obj['evalDebugLog'] = EvalDebugLog.constructFromObject(data['evalDebugLog']); - } + if (data.hasOwnProperty('flagID')) + obj.flagID = ApiClient.convertToType(data['flagID'], 'Number'); + if (data.hasOwnProperty('flagKey')) + obj.flagKey = ApiClient.convertToType(data['flagKey'], 'String'); + if (data.hasOwnProperty('flagSnapshotID')) + obj.flagSnapshotID = ApiClient.convertToType(data['flagSnapshotID'], 'Number'); + if (data.hasOwnProperty('segmentID')) + obj.segmentID = ApiClient.convertToType(data['segmentID'], 'Number'); + if (data.hasOwnProperty('variantID')) + obj.variantID = ApiClient.convertToType(data['variantID'], 'Number'); + if (data.hasOwnProperty('variantKey')) + obj.variantKey = ApiClient.convertToType(data['variantKey'], 'String'); + if (data.hasOwnProperty('variantAttachment')) + obj.variantAttachment = ApiClient.convertToType(data['variantAttachment'], Object); + if (data.hasOwnProperty('evalContext')) + obj.evalContext = EvalContext.constructFromObject(data['evalContext']); + if (data.hasOwnProperty('timestamp')) + obj.timestamp = ApiClient.convertToType(data['timestamp'], 'String'); + if (data.hasOwnProperty('evalDebugLog')) + obj.evalDebugLog = EvalDebugLog.constructFromObject(data['evalDebugLog']); } return obj; } @@ -107,47 +81,53 @@ /** * @member {Number} flagID */ - exports.prototype['flagID'] = undefined; + exports.prototype.flagID = undefined; + /** * @member {String} flagKey */ - exports.prototype['flagKey'] = undefined; + exports.prototype.flagKey = undefined; + /** * @member {Number} flagSnapshotID */ - exports.prototype['flagSnapshotID'] = undefined; + exports.prototype.flagSnapshotID = undefined; + /** * @member {Number} segmentID */ - exports.prototype['segmentID'] = undefined; + exports.prototype.segmentID = undefined; + /** * @member {Number} variantID */ - exports.prototype['variantID'] = undefined; + exports.prototype.variantID = undefined; + /** * @member {String} variantKey */ - exports.prototype['variantKey'] = undefined; + exports.prototype.variantKey = undefined; + /** * @member {Object} variantAttachment */ - exports.prototype['variantAttachment'] = undefined; + exports.prototype.variantAttachment = undefined; + /** * @member {module:model/EvalContext} evalContext */ - exports.prototype['evalContext'] = undefined; + exports.prototype.evalContext = undefined; + /** * @member {String} timestamp */ - exports.prototype['timestamp'] = undefined; + exports.prototype.timestamp = undefined; + /** * @member {module:model/EvalDebugLog} evalDebugLog */ - exports.prototype['evalDebugLog'] = undefined; - - + exports.prototype.evalDebugLog = undefined; return exports; -})); - +})); diff --git a/src/model/EvaluationBatchRequest.js b/src/model/EvaluationBatchRequest.js index 59145bd..3538e16 100644 --- a/src/model/EvaluationBatchRequest.js +++ b/src/model/EvaluationBatchRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, EvaluationEntity) { 'use strict'; - - - /** * The EvaluationBatchRequest model module. * @module model/EvaluationBatchRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,12 +43,7 @@ * @param entities {Array.} */ var exports = function(entities) { - var _this = this; - - _this['entities'] = entities; - - - + this.entities = entities; }; /** @@ -64,19 +56,16 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('entities')) { - obj['entities'] = ApiClient.convertToType(data['entities'], [EvaluationEntity]); - } - if (data.hasOwnProperty('enableDebug')) { - obj['enableDebug'] = ApiClient.convertToType(data['enableDebug'], 'Boolean'); - } - if (data.hasOwnProperty('flagIDs')) { - obj['flagIDs'] = ApiClient.convertToType(data['flagIDs'], ['Number']); - } - if (data.hasOwnProperty('flagKeys')) { - obj['flagKeys'] = ApiClient.convertToType(data['flagKeys'], ['String']); - } + if (data.hasOwnProperty('entities')) + obj.entities = ApiClient.convertToType(data['entities'], [EvaluationEntity]); + if (data.hasOwnProperty('enableDebug')) + obj.enableDebug = ApiClient.convertToType(data['enableDebug'], 'Boolean'); + if (data.hasOwnProperty('flagIDs')) + obj.flagIDs = ApiClient.convertToType(data['flagIDs'], ['Number']); + if (data.hasOwnProperty('flagKeys')) + obj.flagKeys = ApiClient.convertToType(data['flagKeys'], ['String']); + if (data.hasOwnProperty('flagTags')) + obj.flagTags = ApiClient.convertToType(data['flagTags'], ['String']); } return obj; } @@ -84,25 +73,31 @@ /** * @member {Array.} entities */ - exports.prototype['entities'] = undefined; + exports.prototype.entities = undefined; + /** * @member {Boolean} enableDebug */ - exports.prototype['enableDebug'] = undefined; + exports.prototype.enableDebug = undefined; + /** * flagIDs * @member {Array.} flagIDs */ - exports.prototype['flagIDs'] = undefined; + exports.prototype.flagIDs = undefined; + /** - * flagKeys. Either flagIDs or flagKeys works. If pass in both, Flagr may return duplicate results. + * flagKeys. Either flagIDs, flagKeys or flagTags works. If pass in multiples, Flagr may return duplicate results. * @member {Array.} flagKeys */ - exports.prototype['flagKeys'] = undefined; - + exports.prototype.flagKeys = undefined; + /** + * flagTags. Either flagIDs, flagKeys or flagTags works. If pass in multiples, Flagr may return duplicate results. + * @member {Array.} flagTags + */ + exports.prototype.flagTags = undefined; return exports; -})); - +})); diff --git a/src/model/EvaluationBatchResponse.js b/src/model/EvaluationBatchResponse.js index 84f2d4a..775960c 100644 --- a/src/model/EvaluationBatchResponse.js +++ b/src/model/EvaluationBatchResponse.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, EvalResult) { 'use strict'; - - - /** * The EvaluationBatchResponse model module. * @module model/EvaluationBatchResponse - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,9 +43,7 @@ * @param evaluationResults {Array.} */ var exports = function(evaluationResults) { - var _this = this; - - _this['evaluationResults'] = evaluationResults; + this.evaluationResults = evaluationResults; }; /** @@ -61,10 +56,8 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('evaluationResults')) { - obj['evaluationResults'] = ApiClient.convertToType(data['evaluationResults'], [EvalResult]); - } + if (data.hasOwnProperty('evaluationResults')) + obj.evaluationResults = ApiClient.convertToType(data['evaluationResults'], [EvalResult]); } return obj; } @@ -72,11 +65,8 @@ /** * @member {Array.} evaluationResults */ - exports.prototype['evaluationResults'] = undefined; - - + exports.prototype.evaluationResults = undefined; return exports; -})); - +})); diff --git a/src/model/EvaluationEntity.js b/src/model/EvaluationEntity.js index 5b4328e..36296a4 100644 --- a/src/model/EvaluationEntity.js +++ b/src/model/EvaluationEntity.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The EvaluationEntity model module. * @module model/EvaluationEntity - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -45,11 +42,6 @@ * @class */ var exports = function() { - var _this = this; - - - - }; /** @@ -62,16 +54,12 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('entityID')) { - obj['entityID'] = ApiClient.convertToType(data['entityID'], 'String'); - } - if (data.hasOwnProperty('entityType')) { - obj['entityType'] = ApiClient.convertToType(data['entityType'], 'String'); - } - if (data.hasOwnProperty('entityContext')) { - obj['entityContext'] = ApiClient.convertToType(data['entityContext'], Object); - } + if (data.hasOwnProperty('entityID')) + obj.entityID = ApiClient.convertToType(data['entityID'], 'String'); + if (data.hasOwnProperty('entityType')) + obj.entityType = ApiClient.convertToType(data['entityType'], 'String'); + if (data.hasOwnProperty('entityContext')) + obj.entityContext = ApiClient.convertToType(data['entityContext'], Object); } return obj; } @@ -79,19 +67,18 @@ /** * @member {String} entityID */ - exports.prototype['entityID'] = undefined; + exports.prototype.entityID = undefined; + /** * @member {String} entityType */ - exports.prototype['entityType'] = undefined; + exports.prototype.entityType = undefined; + /** * @member {Object} entityContext */ - exports.prototype['entityContext'] = undefined; - - + exports.prototype.entityContext = undefined; return exports; -})); - +})); diff --git a/src/model/Flag.js b/src/model/Flag.js index bb71037..f433cae 100644 --- a/src/model/Flag.js +++ b/src/model/Flag.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -16,27 +16,24 @@ (function(root, factory) { if (typeof define === 'function' && define.amd) { // AMD. Register as an anonymous module. - define(['ApiClient', 'model/Segment', 'model/Variant'], factory); + define(['ApiClient', 'model/Segment', 'model/Tag', 'model/Variant'], factory); } else if (typeof module === 'object' && module.exports) { // CommonJS-like environments that support module.exports, like Node. - module.exports = factory(require('../ApiClient'), require('./Segment'), require('./Variant')); + module.exports = factory(require('../ApiClient'), require('./Segment'), require('./Tag'), require('./Variant')); } else { // Browser globals (root is window) if (!root.Jsflagr) { root.Jsflagr = {}; } - root.Jsflagr.Flag = factory(root.Jsflagr.ApiClient, root.Jsflagr.Segment, root.Jsflagr.Variant); + root.Jsflagr.Flag = factory(root.Jsflagr.ApiClient, root.Jsflagr.Segment, root.Jsflagr.Tag, root.Jsflagr.Variant); } -}(this, function(ApiClient, Segment, Variant) { +}(this, function(ApiClient, Segment, Tag, Variant) { 'use strict'; - - - /** * The Flag model module. * @module model/Flag - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,19 +45,9 @@ * @param dataRecordsEnabled {Boolean} enabled data records will get data logging in the metrics pipeline, for example, kafka. */ var exports = function(description, enabled, dataRecordsEnabled) { - var _this = this; - - - - _this['description'] = description; - _this['enabled'] = enabled; - - - _this['dataRecordsEnabled'] = dataRecordsEnabled; - - - - + this.description = description; + this.enabled = enabled; + this.dataRecordsEnabled = dataRecordsEnabled; }; /** @@ -73,40 +60,32 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('id')) { - obj['id'] = ApiClient.convertToType(data['id'], 'Number'); - } - if (data.hasOwnProperty('key')) { - obj['key'] = ApiClient.convertToType(data['key'], 'String'); - } - if (data.hasOwnProperty('description')) { - obj['description'] = ApiClient.convertToType(data['description'], 'String'); - } - if (data.hasOwnProperty('enabled')) { - obj['enabled'] = ApiClient.convertToType(data['enabled'], 'Boolean'); - } - if (data.hasOwnProperty('segments')) { - obj['segments'] = ApiClient.convertToType(data['segments'], [Segment]); - } - if (data.hasOwnProperty('variants')) { - obj['variants'] = ApiClient.convertToType(data['variants'], [Variant]); - } - if (data.hasOwnProperty('dataRecordsEnabled')) { - obj['dataRecordsEnabled'] = ApiClient.convertToType(data['dataRecordsEnabled'], 'Boolean'); - } - if (data.hasOwnProperty('entityType')) { - obj['entityType'] = ApiClient.convertToType(data['entityType'], 'String'); - } - if (data.hasOwnProperty('createdBy')) { - obj['createdBy'] = ApiClient.convertToType(data['createdBy'], 'String'); - } - if (data.hasOwnProperty('updatedBy')) { - obj['updatedBy'] = ApiClient.convertToType(data['updatedBy'], 'String'); - } - if (data.hasOwnProperty('updatedAt')) { - obj['updatedAt'] = ApiClient.convertToType(data['updatedAt'], 'Date'); - } + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('key')) + obj.key = ApiClient.convertToType(data['key'], 'String'); + if (data.hasOwnProperty('description')) + obj.description = ApiClient.convertToType(data['description'], 'String'); + if (data.hasOwnProperty('enabled')) + obj.enabled = ApiClient.convertToType(data['enabled'], 'Boolean'); + if (data.hasOwnProperty('tags')) + obj.tags = ApiClient.convertToType(data['tags'], [Tag]); + if (data.hasOwnProperty('segments')) + obj.segments = ApiClient.convertToType(data['segments'], [Segment]); + if (data.hasOwnProperty('variants')) + obj.variants = ApiClient.convertToType(data['variants'], [Variant]); + if (data.hasOwnProperty('dataRecordsEnabled')) + obj.dataRecordsEnabled = ApiClient.convertToType(data['dataRecordsEnabled'], 'Boolean'); + if (data.hasOwnProperty('entityType')) + obj.entityType = ApiClient.convertToType(data['entityType'], 'String'); + if (data.hasOwnProperty('notes')) + obj.notes = ApiClient.convertToType(data['notes'], 'String'); + if (data.hasOwnProperty('createdBy')) + obj.createdBy = ApiClient.convertToType(data['createdBy'], 'String'); + if (data.hasOwnProperty('updatedBy')) + obj.updatedBy = ApiClient.convertToType(data['updatedBy'], 'String'); + if (data.hasOwnProperty('updatedAt')) + obj.updatedAt = ApiClient.convertToType(data['updatedAt'], 'Date'); } return obj; } @@ -114,54 +93,72 @@ /** * @member {Number} id */ - exports.prototype['id'] = undefined; + exports.prototype.id = undefined; + /** * unique key representation of the flag * @member {String} key */ - exports.prototype['key'] = undefined; + exports.prototype.key = undefined; + /** * @member {String} description */ - exports.prototype['description'] = undefined; + exports.prototype.description = undefined; + /** * @member {Boolean} enabled */ - exports.prototype['enabled'] = undefined; + exports.prototype.enabled = undefined; + + /** + * @member {Array.} tags + */ + exports.prototype.tags = undefined; + /** * @member {Array.} segments */ - exports.prototype['segments'] = undefined; + exports.prototype.segments = undefined; + /** * @member {Array.} variants */ - exports.prototype['variants'] = undefined; + exports.prototype.variants = undefined; + /** * enabled data records will get data logging in the metrics pipeline, for example, kafka. * @member {Boolean} dataRecordsEnabled */ - exports.prototype['dataRecordsEnabled'] = undefined; + exports.prototype.dataRecordsEnabled = undefined; + /** * it will override the entityType in the evaluation logs if it's not empty * @member {String} entityType */ - exports.prototype['entityType'] = undefined; + exports.prototype.entityType = undefined; + + /** + * flag usage details in markdown format + * @member {String} notes + */ + exports.prototype.notes = undefined; + /** * @member {String} createdBy */ - exports.prototype['createdBy'] = undefined; + exports.prototype.createdBy = undefined; + /** * @member {String} updatedBy */ - exports.prototype['updatedBy'] = undefined; + exports.prototype.updatedBy = undefined; + /** * @member {Date} updatedAt */ - exports.prototype['updatedAt'] = undefined; - - + exports.prototype.updatedAt = undefined; return exports; -})); - +})); diff --git a/src/model/FlagSnapshot.js b/src/model/FlagSnapshot.js index d8093fb..4f64630 100644 --- a/src/model/FlagSnapshot.js +++ b/src/model/FlagSnapshot.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, Flag) { 'use strict'; - - - /** * The FlagSnapshot model module. * @module model/FlagSnapshot - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,12 +45,9 @@ * @param updatedAt {String} */ var exports = function(id, flag, updatedAt) { - var _this = this; - - _this['id'] = id; - - _this['flag'] = flag; - _this['updatedAt'] = updatedAt; + this.id = id; + this.flag = flag; + this.updatedAt = updatedAt; }; /** @@ -66,19 +60,14 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('id')) { - obj['id'] = ApiClient.convertToType(data['id'], 'Number'); - } - if (data.hasOwnProperty('updatedBy')) { - obj['updatedBy'] = ApiClient.convertToType(data['updatedBy'], 'String'); - } - if (data.hasOwnProperty('flag')) { - obj['flag'] = Flag.constructFromObject(data['flag']); - } - if (data.hasOwnProperty('updatedAt')) { - obj['updatedAt'] = ApiClient.convertToType(data['updatedAt'], 'String'); - } + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('updatedBy')) + obj.updatedBy = ApiClient.convertToType(data['updatedBy'], 'String'); + if (data.hasOwnProperty('flag')) + obj.flag = Flag.constructFromObject(data['flag']); + if (data.hasOwnProperty('updatedAt')) + obj.updatedAt = ApiClient.convertToType(data['updatedAt'], 'String'); } return obj; } @@ -86,23 +75,23 @@ /** * @member {Number} id */ - exports.prototype['id'] = undefined; + exports.prototype.id = undefined; + /** * @member {String} updatedBy */ - exports.prototype['updatedBy'] = undefined; + exports.prototype.updatedBy = undefined; + /** * @member {module:model/Flag} flag */ - exports.prototype['flag'] = undefined; + exports.prototype.flag = undefined; + /** * @member {String} updatedAt */ - exports.prototype['updatedAt'] = undefined; - - + exports.prototype.updatedAt = undefined; return exports; -})); - +})); diff --git a/src/model/Health.js b/src/model/Health.js new file mode 100644 index 0000000..b9970d3 --- /dev/null +++ b/src/model/Health.js @@ -0,0 +1,70 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. Register as an anonymous module. + define(['ApiClient'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + module.exports = factory(require('../ApiClient')); + } else { + // Browser globals (root is window) + if (!root.Jsflagr) { + root.Jsflagr = {}; + } + root.Jsflagr.Health = factory(root.Jsflagr.ApiClient); + } +}(this, function(ApiClient) { + 'use strict'; + + /** + * The Health model module. + * @module model/Health + * @version 1.1.10 + */ + + /** + * Constructs a new Health. + * @alias module:model/Health + * @class + */ + var exports = function() { + }; + + /** + * Constructs a Health from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/Health} obj Optional instance to populate. + * @return {module:model/Health} The populated Health instance. + */ + exports.constructFromObject = function(data, obj) { + if (data) { + obj = obj || new exports(); + if (data.hasOwnProperty('status')) + obj.status = ApiClient.convertToType(data['status'], 'String'); + } + return obj; + } + + /** + * @member {String} status + */ + exports.prototype.status = undefined; + + return exports; + +})); diff --git a/src/model/PutDistributionsRequest.js b/src/model/PutDistributionsRequest.js index 6fd0758..aeaec7f 100644 --- a/src/model/PutDistributionsRequest.js +++ b/src/model/PutDistributionsRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, Distribution) { 'use strict'; - - - /** * The PutDistributionsRequest model module. * @module model/PutDistributionsRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,9 +43,7 @@ * @param distributions {Array.} */ var exports = function(distributions) { - var _this = this; - - _this['distributions'] = distributions; + this.distributions = distributions; }; /** @@ -61,10 +56,8 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('distributions')) { - obj['distributions'] = ApiClient.convertToType(data['distributions'], [Distribution]); - } + if (data.hasOwnProperty('distributions')) + obj.distributions = ApiClient.convertToType(data['distributions'], [Distribution]); } return obj; } @@ -72,11 +65,8 @@ /** * @member {Array.} distributions */ - exports.prototype['distributions'] = undefined; - - + exports.prototype.distributions = undefined; return exports; -})); - +})); diff --git a/src/model/PutFlagRequest.js b/src/model/PutFlagRequest.js index cf8a7b5..5f08af4 100644 --- a/src/model/PutFlagRequest.js +++ b/src/model/PutFlagRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The PutFlagRequest model module. * @module model/PutFlagRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -45,13 +42,6 @@ * @class */ var exports = function() { - var _this = this; - - - - - - }; /** @@ -64,22 +54,18 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('description')) { - obj['description'] = ApiClient.convertToType(data['description'], 'String'); - } - if (data.hasOwnProperty('dataRecordsEnabled')) { - obj['dataRecordsEnabled'] = ApiClient.convertToType(data['dataRecordsEnabled'], 'Boolean'); - } - if (data.hasOwnProperty('entityType')) { - obj['entityType'] = ApiClient.convertToType(data['entityType'], 'String'); - } - if (data.hasOwnProperty('enabled')) { - obj['enabled'] = ApiClient.convertToType(data['enabled'], 'Boolean'); - } - if (data.hasOwnProperty('key')) { - obj['key'] = ApiClient.convertToType(data['key'], 'String'); - } + if (data.hasOwnProperty('description')) + obj.description = ApiClient.convertToType(data['description'], 'String'); + if (data.hasOwnProperty('dataRecordsEnabled')) + obj.dataRecordsEnabled = ApiClient.convertToType(data['dataRecordsEnabled'], 'Boolean'); + if (data.hasOwnProperty('entityType')) + obj.entityType = ApiClient.convertToType(data['entityType'], 'String'); + if (data.hasOwnProperty('enabled')) + obj.enabled = ApiClient.convertToType(data['enabled'], 'Boolean'); + if (data.hasOwnProperty('key')) + obj.key = ApiClient.convertToType(data['key'], 'String'); + if (data.hasOwnProperty('notes')) + obj.notes = ApiClient.convertToType(data['notes'], 'String'); } return obj; } @@ -87,29 +73,35 @@ /** * @member {String} description */ - exports.prototype['description'] = undefined; + exports.prototype.description = undefined; + /** * enabled data records will get data logging in the metrics pipeline, for example, kafka. * @member {Boolean} dataRecordsEnabled */ - exports.prototype['dataRecordsEnabled'] = undefined; + exports.prototype.dataRecordsEnabled = undefined; + /** * it will overwrite entityType into evaluation logs if it's not empty * @member {String} entityType */ - exports.prototype['entityType'] = undefined; + exports.prototype.entityType = undefined; + /** * @member {Boolean} enabled */ - exports.prototype['enabled'] = undefined; + exports.prototype.enabled = undefined; + /** * @member {String} key */ - exports.prototype['key'] = undefined; - + exports.prototype.key = undefined; + /** + * @member {String} notes + */ + exports.prototype.notes = undefined; return exports; -})); - +})); diff --git a/src/model/PutSegmentReorderRequest.js b/src/model/PutSegmentReorderRequest.js index 47eaf90..720cf8e 100644 --- a/src/model/PutSegmentReorderRequest.js +++ b/src/model/PutSegmentReorderRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The PutSegmentReorderRequest model module. * @module model/PutSegmentReorderRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,9 +43,7 @@ * @param segmentIDs {Array.} */ var exports = function(segmentIDs) { - var _this = this; - - _this['segmentIDs'] = segmentIDs; + this.segmentIDs = segmentIDs; }; /** @@ -61,10 +56,8 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('segmentIDs')) { - obj['segmentIDs'] = ApiClient.convertToType(data['segmentIDs'], ['Number']); - } + if (data.hasOwnProperty('segmentIDs')) + obj.segmentIDs = ApiClient.convertToType(data['segmentIDs'], ['Number']); } return obj; } @@ -72,11 +65,8 @@ /** * @member {Array.} segmentIDs */ - exports.prototype['segmentIDs'] = undefined; - - + exports.prototype.segmentIDs = undefined; return exports; -})); - +})); diff --git a/src/model/PutSegmentRequest.js b/src/model/PutSegmentRequest.js index 316b295..0b41d6e 100644 --- a/src/model/PutSegmentRequest.js +++ b/src/model/PutSegmentRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The PutSegmentRequest model module. * @module model/PutSegmentRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -47,10 +44,8 @@ * @param rolloutPercent {Number} */ var exports = function(description, rolloutPercent) { - var _this = this; - - _this['description'] = description; - _this['rolloutPercent'] = rolloutPercent; + this.description = description; + this.rolloutPercent = rolloutPercent; }; /** @@ -63,13 +58,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('description')) { - obj['description'] = ApiClient.convertToType(data['description'], 'String'); - } - if (data.hasOwnProperty('rolloutPercent')) { - obj['rolloutPercent'] = ApiClient.convertToType(data['rolloutPercent'], 'Number'); - } + if (data.hasOwnProperty('description')) + obj.description = ApiClient.convertToType(data['description'], 'String'); + if (data.hasOwnProperty('rolloutPercent')) + obj.rolloutPercent = ApiClient.convertToType(data['rolloutPercent'], 'Number'); } return obj; } @@ -77,15 +69,13 @@ /** * @member {String} description */ - exports.prototype['description'] = undefined; + exports.prototype.description = undefined; + /** * @member {Number} rolloutPercent */ - exports.prototype['rolloutPercent'] = undefined; - - + exports.prototype.rolloutPercent = undefined; return exports; -})); - +})); diff --git a/src/model/PutVariantRequest.js b/src/model/PutVariantRequest.js index b1e6529..e9ef5b7 100644 --- a/src/model/PutVariantRequest.js +++ b/src/model/PutVariantRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The PutVariantRequest model module. * @module model/PutVariantRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,10 +43,7 @@ * @param key {String} */ var exports = function(key) { - var _this = this; - - _this['key'] = key; - + this.key = key; }; /** @@ -62,13 +56,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('key')) { - obj['key'] = ApiClient.convertToType(data['key'], 'String'); - } - if (data.hasOwnProperty('attachment')) { - obj['attachment'] = ApiClient.convertToType(data['attachment'], Object); - } + if (data.hasOwnProperty('key')) + obj.key = ApiClient.convertToType(data['key'], 'String'); + if (data.hasOwnProperty('attachment')) + obj.attachment = ApiClient.convertToType(data['attachment'], Object); } return obj; } @@ -76,15 +67,13 @@ /** * @member {String} key */ - exports.prototype['key'] = undefined; + exports.prototype.key = undefined; + /** * @member {Object} attachment */ - exports.prototype['attachment'] = undefined; - - + exports.prototype.attachment = undefined; return exports; -})); - +})); diff --git a/src/model/Segment.js b/src/model/Segment.js index 79fd036..e0d7efa 100644 --- a/src/model/Segment.js +++ b/src/model/Segment.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient, Constraint, Distribution) { 'use strict'; - - - /** * The Segment model module. * @module model/Segment - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -48,14 +45,9 @@ * @param rolloutPercent {Number} */ var exports = function(description, rank, rolloutPercent) { - var _this = this; - - - _this['description'] = description; - - - _this['rank'] = rank; - _this['rolloutPercent'] = rolloutPercent; + this.description = description; + this.rank = rank; + this.rolloutPercent = rolloutPercent; }; /** @@ -68,25 +60,18 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('id')) { - obj['id'] = ApiClient.convertToType(data['id'], 'Number'); - } - if (data.hasOwnProperty('description')) { - obj['description'] = ApiClient.convertToType(data['description'], 'String'); - } - if (data.hasOwnProperty('constraints')) { - obj['constraints'] = ApiClient.convertToType(data['constraints'], [Constraint]); - } - if (data.hasOwnProperty('distributions')) { - obj['distributions'] = ApiClient.convertToType(data['distributions'], [Distribution]); - } - if (data.hasOwnProperty('rank')) { - obj['rank'] = ApiClient.convertToType(data['rank'], 'Number'); - } - if (data.hasOwnProperty('rolloutPercent')) { - obj['rolloutPercent'] = ApiClient.convertToType(data['rolloutPercent'], 'Number'); - } + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('description')) + obj.description = ApiClient.convertToType(data['description'], 'String'); + if (data.hasOwnProperty('constraints')) + obj.constraints = ApiClient.convertToType(data['constraints'], [Constraint]); + if (data.hasOwnProperty('distributions')) + obj.distributions = ApiClient.convertToType(data['distributions'], [Distribution]); + if (data.hasOwnProperty('rank')) + obj.rank = ApiClient.convertToType(data['rank'], 'Number'); + if (data.hasOwnProperty('rolloutPercent')) + obj.rolloutPercent = ApiClient.convertToType(data['rolloutPercent'], 'Number'); } return obj; } @@ -94,31 +79,33 @@ /** * @member {Number} id */ - exports.prototype['id'] = undefined; + exports.prototype.id = undefined; + /** * @member {String} description */ - exports.prototype['description'] = undefined; + exports.prototype.description = undefined; + /** * @member {Array.} constraints */ - exports.prototype['constraints'] = undefined; + exports.prototype.constraints = undefined; + /** * @member {Array.} distributions */ - exports.prototype['distributions'] = undefined; + exports.prototype.distributions = undefined; + /** * @member {Number} rank */ - exports.prototype['rank'] = undefined; + exports.prototype.rank = undefined; + /** * @member {Number} rolloutPercent */ - exports.prototype['rolloutPercent'] = undefined; - - + exports.prototype.rolloutPercent = undefined; return exports; -})); - +})); diff --git a/src/model/SegmentDebugLog.js b/src/model/SegmentDebugLog.js index dfbdb30..a6280ec 100644 --- a/src/model/SegmentDebugLog.js +++ b/src/model/SegmentDebugLog.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The SegmentDebugLog model module. * @module model/SegmentDebugLog - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -45,10 +42,6 @@ * @class */ var exports = function() { - var _this = this; - - - }; /** @@ -61,13 +54,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('segmentID')) { - obj['segmentID'] = ApiClient.convertToType(data['segmentID'], 'Number'); - } - if (data.hasOwnProperty('msg')) { - obj['msg'] = ApiClient.convertToType(data['msg'], 'String'); - } + if (data.hasOwnProperty('segmentID')) + obj.segmentID = ApiClient.convertToType(data['segmentID'], 'Number'); + if (data.hasOwnProperty('msg')) + obj.msg = ApiClient.convertToType(data['msg'], 'String'); } return obj; } @@ -75,15 +65,13 @@ /** * @member {Number} segmentID */ - exports.prototype['segmentID'] = undefined; + exports.prototype.segmentID = undefined; + /** * @member {String} msg */ - exports.prototype['msg'] = undefined; - - + exports.prototype.msg = undefined; return exports; -})); - +})); diff --git a/src/model/SetFlagEnabledRequest.js b/src/model/SetFlagEnabledRequest.js index ea42d12..b5747fc 100644 --- a/src/model/SetFlagEnabledRequest.js +++ b/src/model/SetFlagEnabledRequest.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The SetFlagEnabledRequest model module. * @module model/SetFlagEnabledRequest - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,9 +43,7 @@ * @param enabled {Boolean} */ var exports = function(enabled) { - var _this = this; - - _this['enabled'] = enabled; + this.enabled = enabled; }; /** @@ -61,10 +56,8 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('enabled')) { - obj['enabled'] = ApiClient.convertToType(data['enabled'], 'Boolean'); - } + if (data.hasOwnProperty('enabled')) + obj.enabled = ApiClient.convertToType(data['enabled'], 'Boolean'); } return obj; } @@ -72,11 +65,8 @@ /** * @member {Boolean} enabled */ - exports.prototype['enabled'] = undefined; - - + exports.prototype.enabled = undefined; return exports; -})); - +})); diff --git a/src/model/Tag.js b/src/model/Tag.js new file mode 100644 index 0000000..eeb82fd --- /dev/null +++ b/src/model/Tag.js @@ -0,0 +1,79 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. Register as an anonymous module. + define(['ApiClient'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + module.exports = factory(require('../ApiClient')); + } else { + // Browser globals (root is window) + if (!root.Jsflagr) { + root.Jsflagr = {}; + } + root.Jsflagr.Tag = factory(root.Jsflagr.ApiClient); + } +}(this, function(ApiClient) { + 'use strict'; + + /** + * The Tag model module. + * @module model/Tag + * @version 1.1.10 + */ + + /** + * Constructs a new Tag. + * @alias module:model/Tag + * @class + * @param value {String} + */ + var exports = function(value) { + this.value = value; + }; + + /** + * Constructs a Tag from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/Tag} obj Optional instance to populate. + * @return {module:model/Tag} The populated Tag instance. + */ + exports.constructFromObject = function(data, obj) { + if (data) { + obj = obj || new exports(); + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('value')) + obj.value = ApiClient.convertToType(data['value'], 'String'); + } + return obj; + } + + /** + * @member {Number} id + */ + exports.prototype.id = undefined; + + /** + * @member {String} value + */ + exports.prototype.value = undefined; + + return exports; + +})); diff --git a/src/model/Variant.js b/src/model/Variant.js index 5036327..6868b22 100644 --- a/src/model/Variant.js +++ b/src/model/Variant.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -30,13 +30,10 @@ }(this, function(ApiClient) { 'use strict'; - - - /** * The Variant model module. * @module model/Variant - * @version 1.1.0 + * @version 1.1.10 */ /** @@ -46,11 +43,7 @@ * @param key {String} */ var exports = function(key) { - var _this = this; - - - _this['key'] = key; - + this.key = key; }; /** @@ -63,16 +56,12 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - - if (data.hasOwnProperty('id')) { - obj['id'] = ApiClient.convertToType(data['id'], 'Number'); - } - if (data.hasOwnProperty('key')) { - obj['key'] = ApiClient.convertToType(data['key'], 'String'); - } - if (data.hasOwnProperty('attachment')) { - obj['attachment'] = ApiClient.convertToType(data['attachment'], Object); - } + if (data.hasOwnProperty('id')) + obj.id = ApiClient.convertToType(data['id'], 'Number'); + if (data.hasOwnProperty('key')) + obj.key = ApiClient.convertToType(data['key'], 'String'); + if (data.hasOwnProperty('attachment')) + obj.attachment = ApiClient.convertToType(data['attachment'], Object); } return obj; } @@ -80,19 +69,18 @@ /** * @member {Number} id */ - exports.prototype['id'] = undefined; + exports.prototype.id = undefined; + /** * @member {String} key */ - exports.prototype['key'] = undefined; + exports.prototype.key = undefined; + /** * @member {Object} attachment */ - exports.prototype['attachment'] = undefined; - - + exports.prototype.attachment = undefined; return exports; -})); - +})); diff --git a/swagger.yaml b/swagger.yaml index 7827f9c..50212fd 100644 --- a/swagger.yaml +++ b/swagger.yaml @@ -4,7 +4,7 @@ info: Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is "/api/v1". title: Flagr - version: 1.1.0 + version: 1.1.10 tags: - name: flag description: Everything about the flag @@ -28,6 +28,7 @@ x-tagGroups: - constraint - distribution - variant + - tag - name: Flag Evaluation tags: - evaluation @@ -64,6 +65,10 @@ paths: name: description type: string description: return flags exactly matching given description + - in: query + name: tags + type: string + description: return flags with the given tags (comma separated) - in: query name: description_like type: string @@ -210,6 +215,84 @@ paths: description: generic error response schema: $ref: '#/definitions/error' + '/flags/{flagID}/tags': + get: + tags: + - tag + operationId: findTags + parameters: + - in: path + name: flagID + description: numeric ID of the flag + required: true + type: integer + format: int64 + minimum: 1 + responses: + '200': + description: tag ordered by tagID + schema: + type: array + items: + $ref: '#/definitions/tag' + default: + description: generic error response + schema: + $ref: '#/definitions/error' + post: + tags: + - tag + operationId: createTag + parameters: + - in: path + name: flagID + description: numeric ID of the flag + required: true + type: integer + format: int64 + minimum: 1 + - in: body + name: body + description: create a tag + required: true + schema: + $ref: '#/definitions/createTagRequest' + responses: + '200': + description: tag just created + schema: + $ref: '#/definitions/tag' + default: + description: generic error response + schema: + $ref: '#/definitions/error' + '/flags/{flagID}/tags/{tagID}': + delete: + tags: + - tag + operationId: deleteTag + parameters: + - in: path + name: flagID + description: numeric ID of the flag + required: true + type: integer + format: int64 + minimum: 1 + - in: path + name: tagID + description: numeric ID of the tag + required: true + type: integer + format: int64 + minimum: 1 + responses: + '200': + description: deleted + default: + description: generic error response + schema: + $ref: '#/definitions/error' '/flags/{flagID}/variants': get: tags: @@ -709,6 +792,39 @@ paths: description: generic error response schema: $ref: '#/definitions/error' + /tags: + get: + tags: + - tag + operationId: findAllTags + parameters: + - in: query + name: limit + type: integer + format: int64 + description: the numbers of tags to return + - in: query + name: offset + type: integer + format: int64 + description: >- + return tags given the offset, it should usually set together with + limit + - in: query + name: value_like + type: string + description: return tags partially matching given value + responses: + '200': + description: list all the tags + schema: + type: array + items: + $ref: '#/definitions/tag' + default: + description: generic error response + schema: + $ref: '#/definitions/error' /evaluation: post: tags: @@ -759,7 +875,9 @@ paths: description: Check if Flagr is healthy responses: '200': - description: OK + description: status of health check + schema: + $ref: '#/definitions/health' default: description: generic error response schema: @@ -768,7 +886,14 @@ paths: get: tags: - export - operationId: getExportSQLite + operationId: getExportSqlite + parameters: + - in: query + name: exclude_snapshots + type: boolean + description: > + export without snapshots data - useful for smaller db without + snapshots description: >- Export sqlite3 format of the db dump, which is converted from the main database. @@ -783,6 +908,23 @@ paths: description: generic error response schema: $ref: '#/definitions/error' + /export/eval_cache/json: + get: + tags: + - export + operationId: getExportEvalCacheJSON + description: Export JSON format of the eval cache dump + produces: + - application/json + responses: + '200': + description: OK + schema: + type: object + default: + description: generic error response + schema: + $ref: '#/definitions/error' definitions: flag: type: object @@ -805,6 +947,10 @@ definitions: minLength: 1 enabled: type: boolean + tags: + type: array + items: + $ref: '#/definitions/tag' segments: type: array items: @@ -823,6 +969,9 @@ definitions: it will override the entityType in the evaluation logs if it's not empty type: string + notes: + description: flag usage details in markdown format + type: string createdBy: type: string updatedBy: @@ -841,6 +990,9 @@ definitions: key: description: unique key representation of the flag type: string + template: + description: template for flag creation + type: string putFlagRequest: type: object properties: @@ -864,6 +1016,9 @@ definitions: key: type: string x-nullable: true + notes: + type: string + x-nullable: true setFlagEnabledRequest: type: object required: @@ -889,6 +1044,27 @@ definitions: updatedAt: type: string minLength: 1 + tag: + type: object + required: + - value + properties: + id: + type: integer + format: int64 + minimum: 1 + readOnly: true + value: + type: string + minLength: 1 + createTagRequest: + type: object + required: + - value + properties: + value: + type: string + minLength: 1 segment: type: object required: @@ -1103,6 +1279,12 @@ definitions: flagKey. flagID or flagKey will resolve to the same flag. Either works. type: string + flagTags: + description: flagTags. flagTags looks up flags by tag. Either works. + type: array + x-omitempty: true + items: + type: string evalResult: type: object properties: @@ -1179,8 +1361,17 @@ definitions: minItems: 1 flagKeys: description: >- - flagKeys. Either flagIDs or flagKeys works. If pass in both, Flagr may - return duplicate results. + flagKeys. Either flagIDs, flagKeys or flagTags works. If pass in + multiples, Flagr may return duplicate results. + type: array + items: + type: string + minLength: 1 + minItems: 1 + flagTags: + description: >- + flagTags. Either flagIDs, flagKeys or flagTags works. If pass in + multiples, Flagr may return duplicate results. type: array items: type: string @@ -1195,6 +1386,11 @@ definitions: type: array items: $ref: '#/definitions/evalResult' + health: + type: object + properties: + status: + type: string error: type: object required: diff --git a/test/api/ConstraintApi.spec.js b/test/api/ConstraintApi.spec.js index 40a317a..5eef187 100644 --- a/test/api/ConstraintApi.spec.js +++ b/test/api/ConstraintApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,61 +33,133 @@ instance = new Jsflagr.ConstraintApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('ConstraintApi', function() { + describe('createConstraint', function() { + it('should call createConstraint successfully', function(done) { + // TODO: uncomment, update parameter values for createConstraint call and complete the assertions + /* + var flagID = 789; + var segmentID = 789; + var body = new Jsflagr.CreateConstraintRequest(); + body.property = ""; + body.operator = ""; + body.value = ""; - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.createConstraint(flagID, segmentID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); - describe('ConstraintApi', function() { - describe('createConstraint', function() { - it('should call createConstraint successfully', function(done) { - //uncomment below and update the code to test createConstraint - //instance.createConstraint(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('deleteConstraint', function() { - it('should call deleteConstraint successfully', function(done) { - //uncomment below and update the code to test deleteConstraint - //instance.deleteConstraint(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('deleteConstraint', function() { + it('should call deleteConstraint successfully', function(done) { + // TODO: uncomment, update parameter values for deleteConstraint call + /* + var flagID = 789; + var segmentID = 789; + var constraintID = 789; + + instance.deleteConstraint(flagID, segmentID, constraintID, function(error, data, response) { + if (error) { + done(error); + return; + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('findConstraints', function() { - it('should call findConstraints successfully', function(done) { - //uncomment below and update the code to test findConstraints - //instance.findConstraints(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('findConstraints', function() { + it('should call findConstraints successfully', function(done) { + // TODO: uncomment, update parameter values for findConstraints call and complete the assertions + /* + var flagID = 789; + var segmentID = 789; + + instance.findConstraints(flagID, segmentID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('putConstraint', function() { - it('should call putConstraint successfully', function(done) { - //uncomment below and update the code to test putConstraint - //instance.putConstraint(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('putConstraint', function() { + it('should call putConstraint successfully', function(done) { + // TODO: uncomment, update parameter values for putConstraint call and complete the assertions + /* + var flagID = 789; + var segmentID = 789; + var constraintID = 789; + var body = new Jsflagr.CreateConstraintRequest(); + body.property = ""; + body.operator = ""; + body.value = ""; + + instance.putConstraint(flagID, segmentID, constraintID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/DistributionApi.spec.js b/test/api/DistributionApi.spec.js index 860a7ca..535d0e4 100644 --- a/test/api/DistributionApi.spec.js +++ b/test/api/DistributionApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,41 +33,84 @@ instance = new Jsflagr.DistributionApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('DistributionApi', function() { + describe('findDistributions', function() { + it('should call findDistributions successfully', function(done) { + // TODO: uncomment, update parameter values for findDistributions call and complete the assertions + /* + var flagID = 789; + var segmentID = 789; - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.findDistributions(flagID, segmentID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + } - describe('DistributionApi', function() { - describe('findDistributions', function() { - it('should call findDistributions successfully', function(done) { - //uncomment below and update the code to test findDistributions - //instance.findDistributions(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('putDistributions', function() { - it('should call putDistributions successfully', function(done) { - //uncomment below and update the code to test putDistributions - //instance.putDistributions(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('putDistributions', function() { + it('should call putDistributions successfully', function(done) { + // TODO: uncomment, update parameter values for putDistributions call and complete the assertions + /* + var flagID = 789; + var segmentID = 789; + var body = new Jsflagr.PutDistributionsRequest(); + body.distributions = [new Jsflagr.Distribution()]; + body.distributions[0].percent = "0"; + body.distributions[0].variantKey = ""; + body.distributions[0].variantID = "0"; + + instance.putDistributions(flagID, segmentID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/EvaluationApi.spec.js b/test/api/EvaluationApi.spec.js index a0f008b..d4ed53e 100644 --- a/test/api/EvaluationApi.spec.js +++ b/test/api/EvaluationApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,41 +33,186 @@ instance = new Jsflagr.EvaluationApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('EvaluationApi', function() { + describe('postEvaluation', function() { + it('should call postEvaluation successfully', function(done) { + // TODO: uncomment, update parameter values for postEvaluation call and complete the assertions + /* + var body = new Jsflagr.EvalContext(); + body.entityID = ""; + body.entityType = ""; + body.entityContext = ; + body.enableDebug = false; + body.flagID = "0"; + body.flagKey = ""; + body.flagTags = [""]; - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.postEvaluation(body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.EvalResult); + expect(data.flagID).to.be.a('number'); + expect(data.flagID).to.be("0"); + expect(data.flagKey).to.be.a('string'); + expect(data.flagKey).to.be(""); + expect(data.flagSnapshotID).to.be.a('number'); + expect(data.flagSnapshotID).to.be("0"); + expect(data.segmentID).to.be.a('number'); + expect(data.segmentID).to.be("0"); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantAttachment).to.be.a(Object); + expect(data.variantAttachment).to.be(); + expect(data.evalContext).to.be.a(Jsflagr.EvalContext); + expect(data.evalContext.entityID).to.be.a('string'); + expect(data.evalContext.entityID).to.be(""); + expect(data.evalContext.entityType).to.be.a('string'); + expect(data.evalContext.entityType).to.be(""); + expect(data.evalContext.entityContext).to.be.a(Object); + expect(data.evalContext.entityContext).to.be(); + expect(data.evalContext.enableDebug).to.be.a('boolean'); + expect(data.evalContext.enableDebug).to.be(false); + expect(data.evalContext.flagID).to.be.a('number'); + expect(data.evalContext.flagID).to.be("0"); + expect(data.evalContext.flagKey).to.be.a('string'); + expect(data.evalContext.flagKey).to.be(""); + { + let dataCtr = data.evalContext.flagTags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a('string'); + expect(data).to.be(""); + } + } + expect(data.timestamp).to.be.a('string'); + expect(data.timestamp).to.be(""); + expect(data.evalDebugLog).to.be.a(Jsflagr.EvalDebugLog); + { + let dataCtr = data.evalDebugLog.segmentDebugLogs; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.SegmentDebugLog); + expect(data.segmentID).to.be.a('number'); + expect(data.segmentID).to.be("0"); + expect(data.msg).to.be.a('string'); + expect(data.msg).to.be(""); + + } + } + expect(data.evalDebugLog.msg).to.be.a('string'); + expect(data.evalDebugLog.msg).to.be(""); - describe('EvaluationApi', function() { - describe('postEvaluation', function() { - it('should call postEvaluation successfully', function(done) { - //uncomment below and update the code to test postEvaluation - //instance.postEvaluation(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('postEvaluationBatch', function() { - it('should call postEvaluationBatch successfully', function(done) { - //uncomment below and update the code to test postEvaluationBatch - //instance.postEvaluationBatch(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('postEvaluationBatch', function() { + it('should call postEvaluationBatch successfully', function(done) { + // TODO: uncomment, update parameter values for postEvaluationBatch call and complete the assertions + /* + var body = new Jsflagr.EvaluationBatchRequest(); + body.entities = [new Jsflagr.EvaluationEntity()]; + body.entities[0].entityID = ""; + body.entities[0].entityType = ""; + body.entities[0].entityContext = ; + body.enableDebug = false; + body.flagIDs = ["0"]; + body.flagKeys = [""]; + body.flagTags = [""]; + + instance.postEvaluationBatch(body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.EvaluationBatchResponse); + { + let dataCtr = data.evaluationResults; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.EvalResult); + expect(data.flagID).to.be.a('number'); + expect(data.flagID).to.be("0"); + expect(data.flagKey).to.be.a('string'); + expect(data.flagKey).to.be(""); + expect(data.flagSnapshotID).to.be.a('number'); + expect(data.flagSnapshotID).to.be("0"); + expect(data.segmentID).to.be.a('number'); + expect(data.segmentID).to.be("0"); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantAttachment).to.be.a(Object); + expect(data.variantAttachment).to.be(); + expect(data.evalContext).to.be.a(Jsflagr.EvalContext); + expect(data.evalContext.entityID).to.be.a('string'); + expect(data.evalContext.entityID).to.be(""); + expect(data.evalContext.entityType).to.be.a('string'); + expect(data.evalContext.entityType).to.be(""); + expect(data.evalContext.entityContext).to.be.a(Object); + expect(data.evalContext.entityContext).to.be(); + expect(data.evalContext.enableDebug).to.be.a('boolean'); + expect(data.evalContext.enableDebug).to.be(false); + expect(data.evalContext.flagID).to.be.a('number'); + expect(data.evalContext.flagID).to.be("0"); + expect(data.evalContext.flagKey).to.be.a('string'); + expect(data.evalContext.flagKey).to.be(""); + { + let dataCtr = data.evalContext.flagTags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a('string'); + expect(data).to.be(""); + } + } + expect(data.timestamp).to.be.a('string'); + expect(data.timestamp).to.be(""); + expect(data.evalDebugLog).to.be.a(Jsflagr.EvalDebugLog); + { + let dataCtr = data.evalDebugLog.segmentDebugLogs; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.SegmentDebugLog); + expect(data.segmentID).to.be.a('number'); + expect(data.segmentID).to.be("0"); + expect(data.msg).to.be.a('string'); + expect(data.msg).to.be(""); + + } + } + expect(data.evalDebugLog.msg).to.be.a('string'); + expect(data.evalDebugLog.msg).to.be(""); + + } + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/ExportApi.spec.js b/test/api/ExportApi.spec.js index 6da07d2..c69fc9f 100644 --- a/test/api/ExportApi.spec.js +++ b/test/api/ExportApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,31 +33,51 @@ instance = new Jsflagr.ExportApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('ExportApi', function() { + describe('getExportEvalCacheJSON', function() { + it('should call getExportEvalCacheJSON successfully', function(done) { + // TODO: uncomment getExportEvalCacheJSON call and complete the assertions + /* - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.getExportEvalCacheJSON(function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Object); + // expect(data).to.be(null); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); + }); + describe('getExportSqlite', function() { + it('should call getExportSqlite successfully', function(done) { + // TODO: uncomment, update parameter values for getExportSqlite call and complete the assertions + /* + var opts = {}; + opts.excludeSnapshots = true; + + instance.getExportSqlite(opts, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(File); + // expect(data).to.be(null); - describe('ExportApi', function() { - describe('getExportSQLite', function() { - it('should call getExportSQLite successfully', function(done) { - //uncomment below and update the code to test getExportSQLite - //instance.getExportSQLite(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/FlagApi.spec.js b/test/api/FlagApi.spec.js index 1e8f1ec..baf6338 100644 --- a/test/api/FlagApi.spec.js +++ b/test/api/FlagApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,101 +33,842 @@ instance = new Jsflagr.FlagApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('FlagApi', function() { + describe('createFlag', function() { + it('should call createFlag successfully', function(done) { + // TODO: uncomment, update parameter values for createFlag call and complete the assertions + /* + var body = new Jsflagr.CreateFlagRequest(); + body.description = ""; + body.key = ""; + body.template = ""; - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.createFlag(body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Flag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + expect(data.enabled).to.be.a('boolean'); + expect(data.enabled).to.be(false); + { + let dataCtr = data.tags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.segments; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + } + } + { + let dataCtr = data.variants; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + } + } + expect(data.dataRecordsEnabled).to.be.a('boolean'); + expect(data.dataRecordsEnabled).to.be(false); + expect(data.entityType).to.be.a('string'); + expect(data.entityType).to.be(""); + expect(data.notes).to.be.a('string'); + expect(data.notes).to.be(""); + expect(data.createdBy).to.be.a('string'); + expect(data.createdBy).to.be(""); + expect(data.updatedBy).to.be.a('string'); + expect(data.updatedBy).to.be(""); + expect(data.updatedAt).to.be.a(Date); + expect(data.updatedAt).to.be(new Date()); - describe('FlagApi', function() { - describe('createFlag', function() { - it('should call createFlag successfully', function(done) { - //uncomment below and update the code to test createFlag - //instance.createFlag(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('deleteFlag', function() { - it('should call deleteFlag successfully', function(done) { - //uncomment below and update the code to test deleteFlag - //instance.deleteFlag(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('deleteFlag', function() { + it('should call deleteFlag successfully', function(done) { + // TODO: uncomment, update parameter values for deleteFlag call + /* + var flagID = 789; + + instance.deleteFlag(flagID, function(error, data, response) { + if (error) { + done(error); + return; + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('findFlags', function() { - it('should call findFlags successfully', function(done) { - //uncomment below and update the code to test findFlags - //instance.findFlags(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('findFlags', function() { + it('should call findFlags successfully', function(done) { + // TODO: uncomment, update parameter values for findFlags call and complete the assertions + /* + var opts = {}; + opts.limit = 789; + opts.enabled = true; + opts.description = "description_example"; + opts.tags = "tags_example"; + opts.descriptionLike = "descriptionLike_example"; + opts.key = "key_example"; + opts.offset = 789; + opts.preload = true; + + instance.findFlags(opts, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Flag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + expect(data.enabled).to.be.a('boolean'); + expect(data.enabled).to.be(false); + { + let dataCtr = data.tags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.segments; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + } + } + { + let dataCtr = data.variants; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + } + } + expect(data.dataRecordsEnabled).to.be.a('boolean'); + expect(data.dataRecordsEnabled).to.be(false); + expect(data.entityType).to.be.a('string'); + expect(data.entityType).to.be(""); + expect(data.notes).to.be.a('string'); + expect(data.notes).to.be(""); + expect(data.createdBy).to.be.a('string'); + expect(data.createdBy).to.be(""); + expect(data.updatedBy).to.be.a('string'); + expect(data.updatedBy).to.be(""); + expect(data.updatedAt).to.be.a(Date); + expect(data.updatedAt).to.be(new Date()); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('getFlag', function() { - it('should call getFlag successfully', function(done) { - //uncomment below and update the code to test getFlag - //instance.getFlag(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('getFlag', function() { + it('should call getFlag successfully', function(done) { + // TODO: uncomment, update parameter values for getFlag call and complete the assertions + /* + var flagID = 789; + + instance.getFlag(flagID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Flag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + expect(data.enabled).to.be.a('boolean'); + expect(data.enabled).to.be(false); + { + let dataCtr = data.tags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.segments; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + } + } + { + let dataCtr = data.variants; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + } + } + expect(data.dataRecordsEnabled).to.be.a('boolean'); + expect(data.dataRecordsEnabled).to.be(false); + expect(data.entityType).to.be.a('string'); + expect(data.entityType).to.be(""); + expect(data.notes).to.be.a('string'); + expect(data.notes).to.be(""); + expect(data.createdBy).to.be.a('string'); + expect(data.createdBy).to.be(""); + expect(data.updatedBy).to.be.a('string'); + expect(data.updatedBy).to.be(""); + expect(data.updatedAt).to.be.a(Date); + expect(data.updatedAt).to.be(new Date()); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('getFlagEntityTypes', function() { - it('should call getFlagEntityTypes successfully', function(done) { - //uncomment below and update the code to test getFlagEntityTypes - //instance.getFlagEntityTypes(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('getFlagEntityTypes', function() { + it('should call getFlagEntityTypes successfully', function(done) { + // TODO: uncomment getFlagEntityTypes call and complete the assertions + /* + + instance.getFlagEntityTypes(function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a('string'); + // expect(data).to.be(null); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('getFlagSnapshots', function() { - it('should call getFlagSnapshots successfully', function(done) { - //uncomment below and update the code to test getFlagSnapshots - //instance.getFlagSnapshots(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('getFlagSnapshots', function() { + it('should call getFlagSnapshots successfully', function(done) { + // TODO: uncomment, update parameter values for getFlagSnapshots call and complete the assertions + /* + var flagID = 789; + + instance.getFlagSnapshots(flagID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.FlagSnapshot); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.updatedBy).to.be.a('string'); + expect(data.updatedBy).to.be(""); + expect(data.flag).to.be.a(Jsflagr.Flag); + expect(data.flag.id).to.be.a('number'); + expect(data.flag.id).to.be("0"); + expect(data.flag.key).to.be.a('string'); + expect(data.flag.key).to.be(""); + expect(data.flag.description).to.be.a('string'); + expect(data.flag.description).to.be(""); + expect(data.flag.enabled).to.be.a('boolean'); + expect(data.flag.enabled).to.be(false); + { + let dataCtr = data.flag.tags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.flag.segments; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + } + } + { + let dataCtr = data.flag.variants; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + } + } + expect(data.flag.dataRecordsEnabled).to.be.a('boolean'); + expect(data.flag.dataRecordsEnabled).to.be(false); + expect(data.flag.entityType).to.be.a('string'); + expect(data.flag.entityType).to.be(""); + expect(data.flag.notes).to.be.a('string'); + expect(data.flag.notes).to.be(""); + expect(data.flag.createdBy).to.be.a('string'); + expect(data.flag.createdBy).to.be(""); + expect(data.flag.updatedBy).to.be.a('string'); + expect(data.flag.updatedBy).to.be(""); + expect(data.flag.updatedAt).to.be.a(Date); + expect(data.flag.updatedAt).to.be(new Date()); + expect(data.updatedAt).to.be.a('string'); + expect(data.updatedAt).to.be(""); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('putFlag', function() { - it('should call putFlag successfully', function(done) { - //uncomment below and update the code to test putFlag - //instance.putFlag(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('putFlag', function() { + it('should call putFlag successfully', function(done) { + // TODO: uncomment, update parameter values for putFlag call and complete the assertions + /* + var flagID = 789; + var body = new Jsflagr.PutFlagRequest(); + body.description = ""; + body.dataRecordsEnabled = false; + body.entityType = ""; + body.enabled = false; + body.key = ""; + body.notes = ""; + + instance.putFlag(flagID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Flag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + expect(data.enabled).to.be.a('boolean'); + expect(data.enabled).to.be(false); + { + let dataCtr = data.tags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.segments; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + } + } + { + let dataCtr = data.variants; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + } + } + expect(data.dataRecordsEnabled).to.be.a('boolean'); + expect(data.dataRecordsEnabled).to.be(false); + expect(data.entityType).to.be.a('string'); + expect(data.entityType).to.be(""); + expect(data.notes).to.be.a('string'); + expect(data.notes).to.be(""); + expect(data.createdBy).to.be.a('string'); + expect(data.createdBy).to.be(""); + expect(data.updatedBy).to.be.a('string'); + expect(data.updatedBy).to.be(""); + expect(data.updatedAt).to.be.a(Date); + expect(data.updatedAt).to.be(new Date()); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('setFlagEnabled', function() { - it('should call setFlagEnabled successfully', function(done) { - //uncomment below and update the code to test setFlagEnabled - //instance.setFlagEnabled(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('setFlagEnabled', function() { + it('should call setFlagEnabled successfully', function(done) { + // TODO: uncomment, update parameter values for setFlagEnabled call and complete the assertions + /* + var flagID = 789; + var body = new Jsflagr.SetFlagEnabledRequest(); + body.enabled = false; + + instance.setFlagEnabled(flagID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Flag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + expect(data.enabled).to.be.a('boolean'); + expect(data.enabled).to.be(false); + { + let dataCtr = data.tags; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.segments; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + } + } + { + let dataCtr = data.variants; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + } + } + expect(data.dataRecordsEnabled).to.be.a('boolean'); + expect(data.dataRecordsEnabled).to.be(false); + expect(data.entityType).to.be.a('string'); + expect(data.entityType).to.be(""); + expect(data.notes).to.be.a('string'); + expect(data.notes).to.be(""); + expect(data.createdBy).to.be.a('string'); + expect(data.createdBy).to.be(""); + expect(data.updatedBy).to.be.a('string'); + expect(data.updatedBy).to.be(""); + expect(data.updatedAt).to.be.a(Date); + expect(data.updatedAt).to.be(new Date()); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/HealthApi.spec.js b/test/api/HealthApi.spec.js index 1040d7d..b173246 100644 --- a/test/api/HealthApi.spec.js +++ b/test/api/HealthApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,31 +33,29 @@ instance = new Jsflagr.HealthApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('HealthApi', function() { + describe('getHealth', function() { + it('should call getHealth successfully', function(done) { + // TODO: uncomment getHealth call and complete the assertions + /* - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.getHealth(function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Health); + expect(data.status).to.be.a('string'); + expect(data.status).to.be(""); - describe('HealthApi', function() { - describe('getHealth', function() { - it('should call getHealth successfully', function(done) { - //uncomment below and update the code to test getHealth - //instance.getHealth(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/SegmentApi.spec.js b/test/api/SegmentApi.spec.js index 5715c9a..34fd33e 100644 --- a/test/api/SegmentApi.spec.js +++ b/test/api/SegmentApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,71 +33,256 @@ instance = new Jsflagr.SegmentApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('SegmentApi', function() { + describe('createSegment', function() { + it('should call createSegment successfully', function(done) { + // TODO: uncomment, update parameter values for createSegment call and complete the assertions + /* + var flagID = 789; + var body = new Jsflagr.CreateSegmentRequest(); + body.description = ""; + body.rolloutPercent = "0"; - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.createSegment(flagID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); - describe('SegmentApi', function() { - describe('createSegment', function() { - it('should call createSegment successfully', function(done) { - //uncomment below and update the code to test createSegment - //instance.createSegment(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('deleteSegment', function() { - it('should call deleteSegment successfully', function(done) { - //uncomment below and update the code to test deleteSegment - //instance.deleteSegment(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('deleteSegment', function() { + it('should call deleteSegment successfully', function(done) { + // TODO: uncomment, update parameter values for deleteSegment call + /* + var flagID = 789; + var segmentID = 789; + + instance.deleteSegment(flagID, segmentID, function(error, data, response) { + if (error) { + done(error); + return; + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('findSegments', function() { - it('should call findSegments successfully', function(done) { - //uncomment below and update the code to test findSegments - //instance.findSegments(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('findSegments', function() { + it('should call findSegments successfully', function(done) { + // TODO: uncomment, update parameter values for findSegments call and complete the assertions + /* + var flagID = 789; + + instance.findSegments(flagID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('putSegment', function() { - it('should call putSegment successfully', function(done) { - //uncomment below and update the code to test putSegment - //instance.putSegment(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('putSegment', function() { + it('should call putSegment successfully', function(done) { + // TODO: uncomment, update parameter values for putSegment call and complete the assertions + /* + var flagID = 789; + var segmentID = 789; + var body = new Jsflagr.PutSegmentRequest(); + body.description = ""; + body.rolloutPercent = "0"; + + instance.putSegment(flagID, segmentID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Segment); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.description).to.be.a('string'); + expect(data.description).to.be(""); + { + let dataCtr = data.constraints; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Constraint); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.property).to.be.a('string'); + expect(data.property).to.be(""); + expect(data.operator).to.be.a('string'); + expect(data.operator).to.be("EQ"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + } + } + { + let dataCtr = data.distributions; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Distribution); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.percent).to.be.a('number'); + expect(data.percent).to.be("0"); + expect(data.variantKey).to.be.a('string'); + expect(data.variantKey).to.be(""); + expect(data.variantID).to.be.a('number'); + expect(data.variantID).to.be("0"); + + } + } + expect(data.rank).to.be.a('number'); + expect(data.rank).to.be("0"); + expect(data.rolloutPercent).to.be.a('number'); + expect(data.rolloutPercent).to.be("0"); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('putSegmentsReorder', function() { - it('should call putSegmentsReorder successfully', function(done) { - //uncomment below and update the code to test putSegmentsReorder - //instance.putSegmentsReorder(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('putSegmentsReorder', function() { + it('should call putSegmentsReorder successfully', function(done) { + // TODO: uncomment, update parameter values for putSegmentsReorder call + /* + var flagID = 789; + var body = new Jsflagr.PutSegmentReorderRequest(); + body.segmentIDs = ["0"]; + + instance.putSegmentsReorder(flagID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/api/TagApi.spec.js b/test/api/TagApi.spec.js new file mode 100644 index 0000000..64f7a48 --- /dev/null +++ b/test/api/TagApi.spec.js @@ -0,0 +1,153 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. + define(['expect.js', '../../src/index'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + factory(require('expect.js'), require('../../src/index')); + } else { + // Browser globals (root is window) + factory(root.expect, root.Jsflagr); + } +}(this, function(expect, Jsflagr) { + 'use strict'; + + var instance; + + beforeEach(function() { + instance = new Jsflagr.TagApi(); + }); + + describe('(package)', function() { + describe('TagApi', function() { + describe('createTag', function() { + it('should call createTag successfully', function(done) { + // TODO: uncomment, update parameter values for createTag call and complete the assertions + /* + var flagID = 789; + var body = new Jsflagr.CreateTagRequest(); + body.value = ""; + + instance.createTag(flagID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); + }); + describe('deleteTag', function() { + it('should call deleteTag successfully', function(done) { + // TODO: uncomment, update parameter values for deleteTag call + /* + var flagID = 789; + var tagID = 789; + + instance.deleteTag(flagID, tagID, function(error, data, response) { + if (error) { + done(error); + return; + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); + }); + describe('findAllTags', function() { + it('should call findAllTags successfully', function(done) { + // TODO: uncomment, update parameter values for findAllTags call and complete the assertions + /* + var opts = {}; + opts.limit = 789; + opts.offset = 789; + opts.valueLike = "valueLike_example"; + + instance.findAllTags(opts, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); + }); + describe('findTags', function() { + it('should call findTags successfully', function(done) { + // TODO: uncomment, update parameter values for findTags call and complete the assertions + /* + var flagID = 789; + + instance.findTags(flagID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Tag); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.value).to.be.a('string'); + expect(data.value).to.be(""); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); + }); + }); + }); + +})); diff --git a/test/api/VariantApi.spec.js b/test/api/VariantApi.spec.js index b783cb1..af7af10 100644 --- a/test/api/VariantApi.spec.js +++ b/test/api/VariantApi.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -33,61 +33,121 @@ instance = new Jsflagr.VariantApi(); }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('VariantApi', function() { + describe('createVariant', function() { + it('should call createVariant successfully', function(done) { + // TODO: uncomment, update parameter values for createVariant call and complete the assertions + /* + var flagID = 789; + var body = new Jsflagr.CreateVariantRequest(); + body.key = ""; + body.attachment = ; - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + instance.createVariant(flagID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); - describe('VariantApi', function() { - describe('createVariant', function() { - it('should call createVariant successfully', function(done) { - //uncomment below and update the code to test createVariant - //instance.createVariant(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('deleteVariant', function() { - it('should call deleteVariant successfully', function(done) { - //uncomment below and update the code to test deleteVariant - //instance.deleteVariant(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('deleteVariant', function() { + it('should call deleteVariant successfully', function(done) { + // TODO: uncomment, update parameter values for deleteVariant call + /* + var flagID = 789; + var variantID = 789; + + instance.deleteVariant(flagID, variantID, function(error, data, response) { + if (error) { + done(error); + return; + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('findVariants', function() { - it('should call findVariants successfully', function(done) { - //uncomment below and update the code to test findVariants - //instance.findVariants(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('findVariants', function() { + it('should call findVariants successfully', function(done) { + // TODO: uncomment, update parameter values for findVariants call and complete the assertions + /* + var flagID = 789; + + instance.findVariants(flagID, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + let dataCtr = data; + expect(dataCtr).to.be.an(Array); + expect(dataCtr).to.not.be.empty(); + for (let p in dataCtr) { + let data = dataCtr[p]; + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + } + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); - }); - describe('putVariant', function() { - it('should call putVariant successfully', function(done) { - //uncomment below and update the code to test putVariant - //instance.putVariant(function(error) { - // if (error) throw error; - //expect().to.be(); - //}); - done(); + describe('putVariant', function() { + it('should call putVariant successfully', function(done) { + // TODO: uncomment, update parameter values for putVariant call and complete the assertions + /* + var flagID = 789; + var variantID = 789; + var body = new Jsflagr.PutVariantRequest(); + body.key = ""; + body.attachment = ; + + instance.putVariant(flagID, variantID, body, function(error, data, response) { + if (error) { + done(error); + return; + } + // TODO: update response assertions + expect(data).to.be.a(Jsflagr.Variant); + expect(data.id).to.be.a('number'); + expect(data.id).to.be("0"); + expect(data.key).to.be.a('string'); + expect(data.key).to.be(""); + expect(data.attachment).to.be.a(Object); + expect(data.attachment).to.be(); + + done(); + }); + */ + // TODO: uncomment and complete method invocation above, then delete this line and the next: + done(); + }); }); }); }); diff --git a/test/assert-equals.js b/test/assert-equals.js new file mode 100644 index 0000000..b95cd5f --- /dev/null +++ b/test/assert-equals.js @@ -0,0 +1,81 @@ +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. + define(factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + module.exports = factory(); + } else { + // Browser globals (root is window) + root.assertEquals = factory(); + } +}(this, function() { + 'use strict'; + + var assertEquals = function(expected, actual, ptr) { + if (!ptr) + ptr = ""; + if (actual === expected) + return; + if (expected instanceof Date || actual instanceof Date) { + expected = toISODateString(expected); + actual = toISODateString(actual); + if (actual !== expected) + fail(expected, actual, ptr, "date value incorrect;"); + } + if (!expected || !actual || typeof expected != 'object' && typeof actual != 'object') { + if (typeof actual != typeof expected) + fail(typeof expected, typeof actual, ptr, "value type incorrect;"); + if (actual != expected) + fail(expected, actual, ptr, "value incorrect;"); + } + return checkObject(expected, actual, ptr); + } + + function toISODateString(value) { + if (value instanceof Date) { + // JavaScript's ISO string contains a milliseconds component that must be stripped out. + value = value.toISOString().replace('.000', ''); + } + return value; + } + + function checkObject(expected, actual, ptr) { + if (undefOrNull(expected) || undefOrNull(actual)) + fail(expected, actual, ptr, "missing value;"); + if (typeof expected !== typeof actual) + fail(typeof expected, typeof actual, ptr, "wrong type;"); + if (expected.prototype !== actual.prototype) + fail(expected.prototype, actual.prototype, ptr, "wrong prototype;"); + try { + var expectedKeys = Object.keys(expected); + var actualKeys = Object.keys(actual); + } catch (e) { + fail(expectedKeys, actualKeys, ptr, "wrong keys;"); + } + if (actualKeys.length != expectedKeys.length) + fail(expectedKeys.length, actualKeys.length, ptr, "key count incorrect;"); + expectedKeys.sort(); + actualKeys.sort(); + for (var i = 0; i < expectedKeys.length; i++) { + if (actualKeys[i] != expectedKeys[i]) + fail(expectedKeys, actualKeys, ptr, "wrong keys;"); + } + for (i = 0; i < expectedKeys.length; i++) { + var key = expectedKeys[i]; + assertEquals(expected[key], actual[key], ptr + '/' + key); + } + } + + function undefOrNull(v) { + return v === undefined || v === null; + } + + function fail(expected, actual, ptr, msg) { + var text = ptr + ' ' + msg + " expected: " + expected + ", actual: " + actual; + console.log(text); + throw new Error(text); + } + + return assertEquals; +})); diff --git a/test/model/Constraint.spec.js b/test/model/Constraint.spec.js index 5d0368a..cb3a1ca 100644 --- a/test/model/Constraint.spec.js +++ b/test/model/Constraint.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,57 +29,42 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.Constraint(); - }); + describe('(package)', function() { + describe('Constraint', function() { + beforeEach(function() { + instance = new Jsflagr.Constraint(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of Constraint', function() { + // TODO: update the code to test Constraint + expect(instance).to.be.a(Jsflagr.Constraint); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); - describe('Constraint', function() { - it('should create an instance of Constraint', function() { - // uncomment below and update the code to test Constraint - //var instance = new Jsflagr.Constraint(); - //expect(instance).to.be.a(Jsflagr.Constraint); - }); + it('should have the property property (base name: "property")', function() { + // TODO: update the code to test the property property + expect(instance).to.have.property('property'); + // expect(instance.property).to.be(expectedValueLiteral); + }); - it('should have the property id (base name: "id")', function() { - // uncomment below and update the code to test the property id - //var instance = new Jsflagr.Constraint(); - //expect(instance).to.be(); - }); + it('should have the property operator (base name: "operator")', function() { + // TODO: update the code to test the property operator + expect(instance).to.have.property('operator'); + // expect(instance.operator).to.be(expectedValueLiteral); + }); - it('should have the property property (base name: "property")', function() { - // uncomment below and update the code to test the property property - //var instance = new Jsflagr.Constraint(); - //expect(instance).to.be(); - }); - - it('should have the property operator (base name: "operator")', function() { - // uncomment below and update the code to test the property operator - //var instance = new Jsflagr.Constraint(); - //expect(instance).to.be(); - }); + it('should have the property value (base name: "value")', function() { + // TODO: update the code to test the property value + expect(instance).to.have.property('value'); + // expect(instance.value).to.be(expectedValueLiteral); + }); - it('should have the property value (base name: "value")', function() { - // uncomment below and update the code to test the property value - //var instance = new Jsflagr.Constraint(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/CreateConstraintRequest.spec.js b/test/model/CreateConstraintRequest.spec.js index 9df6d1b..3eb469d 100644 --- a/test/model/CreateConstraintRequest.spec.js +++ b/test/model/CreateConstraintRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,51 +29,36 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.CreateConstraintRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('CreateConstraintRequest', function() { + beforeEach(function() { + instance = new Jsflagr.CreateConstraintRequest(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of CreateConstraintRequest', function() { + // TODO: update the code to test CreateConstraintRequest + expect(instance).to.be.a(Jsflagr.CreateConstraintRequest); + }); - describe('CreateConstraintRequest', function() { - it('should create an instance of CreateConstraintRequest', function() { - // uncomment below and update the code to test CreateConstraintRequest - //var instance = new Jsflagr.CreateConstraintRequest(); - //expect(instance).to.be.a(Jsflagr.CreateConstraintRequest); - }); + it('should have the property property (base name: "property")', function() { + // TODO: update the code to test the property property + expect(instance).to.have.property('property'); + // expect(instance.property).to.be(expectedValueLiteral); + }); - it('should have the property property (base name: "property")', function() { - // uncomment below and update the code to test the property property - //var instance = new Jsflagr.CreateConstraintRequest(); - //expect(instance).to.be(); - }); + it('should have the property operator (base name: "operator")', function() { + // TODO: update the code to test the property operator + expect(instance).to.have.property('operator'); + // expect(instance.operator).to.be(expectedValueLiteral); + }); - it('should have the property operator (base name: "operator")', function() { - // uncomment below and update the code to test the property operator - //var instance = new Jsflagr.CreateConstraintRequest(); - //expect(instance).to.be(); - }); + it('should have the property value (base name: "value")', function() { + // TODO: update the code to test the property value + expect(instance).to.have.property('value'); + // expect(instance.value).to.be(expectedValueLiteral); + }); - it('should have the property value (base name: "value")', function() { - // uncomment below and update the code to test the property value - //var instance = new Jsflagr.CreateConstraintRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/CreateFlagRequest.spec.js b/test/model/CreateFlagRequest.spec.js index 799d2c5..7d99fbf 100644 --- a/test/model/CreateFlagRequest.spec.js +++ b/test/model/CreateFlagRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,36 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.CreateFlagRequest(); - }); + describe('(package)', function() { + describe('CreateFlagRequest', function() { + beforeEach(function() { + instance = new Jsflagr.CreateFlagRequest(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of CreateFlagRequest', function() { + // TODO: update the code to test CreateFlagRequest + expect(instance).to.be.a(Jsflagr.CreateFlagRequest); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property description (base name: "description")', function() { + // TODO: update the code to test the property description + expect(instance).to.have.property('description'); + // expect(instance.description).to.be(expectedValueLiteral); + }); - describe('CreateFlagRequest', function() { - it('should create an instance of CreateFlagRequest', function() { - // uncomment below and update the code to test CreateFlagRequest - //var instance = new Jsflagr.CreateFlagRequest(); - //expect(instance).to.be.a(Jsflagr.CreateFlagRequest); - }); + it('should have the property key (base name: "key")', function() { + // TODO: update the code to test the property key + expect(instance).to.have.property('key'); + // expect(instance.key).to.be(expectedValueLiteral); + }); - it('should have the property description (base name: "description")', function() { - // uncomment below and update the code to test the property description - //var instance = new Jsflagr.CreateFlagRequest(); - //expect(instance).to.be(); - }); + it('should have the property template (base name: "template")', function() { + // TODO: update the code to test the property template + expect(instance).to.have.property('template'); + // expect(instance.template).to.be(expectedValueLiteral); + }); - it('should have the property key (base name: "key")', function() { - // uncomment below and update the code to test the property key - //var instance = new Jsflagr.CreateFlagRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/CreateSegmentRequest.spec.js b/test/model/CreateSegmentRequest.spec.js index d552ac3..c9f38eb 100644 --- a/test/model/CreateSegmentRequest.spec.js +++ b/test/model/CreateSegmentRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,30 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.CreateSegmentRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + describe('(package)', function() { + describe('CreateSegmentRequest', function() { + beforeEach(function() { + instance = new Jsflagr.CreateSegmentRequest(); + }); + + it('should create an instance of CreateSegmentRequest', function() { + // TODO: update the code to test CreateSegmentRequest + expect(instance).to.be.a(Jsflagr.CreateSegmentRequest); + }); + + it('should have the property description (base name: "description")', function() { + // TODO: update the code to test the property description + expect(instance).to.have.property('description'); + // expect(instance.description).to.be(expectedValueLiteral); + }); + + it('should have the property rolloutPercent (base name: "rolloutPercent")', function() { + // TODO: update the code to test the property rolloutPercent + expect(instance).to.have.property('rolloutPercent'); + // expect(instance.rolloutPercent).to.be(expectedValueLiteral); + }); - describe('CreateSegmentRequest', function() { - it('should create an instance of CreateSegmentRequest', function() { - // uncomment below and update the code to test CreateSegmentRequest - //var instance = new Jsflagr.CreateSegmentRequest(); - //expect(instance).to.be.a(Jsflagr.CreateSegmentRequest); }); - - it('should have the property description (base name: "description")', function() { - // uncomment below and update the code to test the property description - //var instance = new Jsflagr.CreateSegmentRequest(); - //expect(instance).to.be(); - }); - - it('should have the property rolloutPercent (base name: "rolloutPercent")', function() { - // uncomment below and update the code to test the property rolloutPercent - //var instance = new Jsflagr.CreateSegmentRequest(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/CreateTagRequest.spec.js b/test/model/CreateTagRequest.spec.js new file mode 100644 index 0000000..24fbc9f --- /dev/null +++ b/test/model/CreateTagRequest.spec.js @@ -0,0 +1,52 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. + define(['expect.js', '../../src/index'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + factory(require('expect.js'), require('../../src/index')); + } else { + // Browser globals (root is window) + factory(root.expect, root.Jsflagr); + } +}(this, function(expect, Jsflagr) { + 'use strict'; + + var instance; + + describe('(package)', function() { + describe('CreateTagRequest', function() { + beforeEach(function() { + instance = new Jsflagr.CreateTagRequest(); + }); + + it('should create an instance of CreateTagRequest', function() { + // TODO: update the code to test CreateTagRequest + expect(instance).to.be.a(Jsflagr.CreateTagRequest); + }); + + it('should have the property value (base name: "value")', function() { + // TODO: update the code to test the property value + expect(instance).to.have.property('value'); + // expect(instance.value).to.be(expectedValueLiteral); + }); + + }); + }); + +})); diff --git a/test/model/CreateVariantRequest.spec.js b/test/model/CreateVariantRequest.spec.js index d1deede..1eb7d63 100644 --- a/test/model/CreateVariantRequest.spec.js +++ b/test/model/CreateVariantRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,30 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.CreateVariantRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + describe('(package)', function() { + describe('CreateVariantRequest', function() { + beforeEach(function() { + instance = new Jsflagr.CreateVariantRequest(); + }); + + it('should create an instance of CreateVariantRequest', function() { + // TODO: update the code to test CreateVariantRequest + expect(instance).to.be.a(Jsflagr.CreateVariantRequest); + }); + + it('should have the property key (base name: "key")', function() { + // TODO: update the code to test the property key + expect(instance).to.have.property('key'); + // expect(instance.key).to.be(expectedValueLiteral); + }); + + it('should have the property attachment (base name: "attachment")', function() { + // TODO: update the code to test the property attachment + expect(instance).to.have.property('attachment'); + // expect(instance.attachment).to.be(expectedValueLiteral); + }); - describe('CreateVariantRequest', function() { - it('should create an instance of CreateVariantRequest', function() { - // uncomment below and update the code to test CreateVariantRequest - //var instance = new Jsflagr.CreateVariantRequest(); - //expect(instance).to.be.a(Jsflagr.CreateVariantRequest); }); - - it('should have the property key (base name: "key")', function() { - // uncomment below and update the code to test the property key - //var instance = new Jsflagr.CreateVariantRequest(); - //expect(instance).to.be(); - }); - - it('should have the property attachment (base name: "attachment")', function() { - // uncomment below and update the code to test the property attachment - //var instance = new Jsflagr.CreateVariantRequest(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/Distribution.spec.js b/test/model/Distribution.spec.js index 3ea8aa3..5aad8df 100644 --- a/test/model/Distribution.spec.js +++ b/test/model/Distribution.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,57 +29,42 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.Distribution(); - }); + describe('(package)', function() { + describe('Distribution', function() { + beforeEach(function() { + instance = new Jsflagr.Distribution(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of Distribution', function() { + // TODO: update the code to test Distribution + expect(instance).to.be.a(Jsflagr.Distribution); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); - describe('Distribution', function() { - it('should create an instance of Distribution', function() { - // uncomment below and update the code to test Distribution - //var instance = new Jsflagr.Distribution(); - //expect(instance).to.be.a(Jsflagr.Distribution); - }); + it('should have the property percent (base name: "percent")', function() { + // TODO: update the code to test the property percent + expect(instance).to.have.property('percent'); + // expect(instance.percent).to.be(expectedValueLiteral); + }); - it('should have the property id (base name: "id")', function() { - // uncomment below and update the code to test the property id - //var instance = new Jsflagr.Distribution(); - //expect(instance).to.be(); - }); + it('should have the property variantKey (base name: "variantKey")', function() { + // TODO: update the code to test the property variantKey + expect(instance).to.have.property('variantKey'); + // expect(instance.variantKey).to.be(expectedValueLiteral); + }); - it('should have the property percent (base name: "percent")', function() { - // uncomment below and update the code to test the property percent - //var instance = new Jsflagr.Distribution(); - //expect(instance).to.be(); - }); - - it('should have the property variantKey (base name: "variantKey")', function() { - // uncomment below and update the code to test the property variantKey - //var instance = new Jsflagr.Distribution(); - //expect(instance).to.be(); - }); + it('should have the property variantID (base name: "variantID")', function() { + // TODO: update the code to test the property variantID + expect(instance).to.have.property('variantID'); + // expect(instance.variantID).to.be(expectedValueLiteral); + }); - it('should have the property variantID (base name: "variantID")', function() { - // uncomment below and update the code to test the property variantID - //var instance = new Jsflagr.Distribution(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/Error.spec.js b/test/model/Error.spec.js index d37f4c8..d186c4e 100644 --- a/test/model/Error.spec.js +++ b/test/model/Error.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,39 +29,24 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.Error(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('Error', function() { + beforeEach(function() { + instance = new Jsflagr.Error(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of Error', function() { + // TODO: update the code to test Error + expect(instance).to.be.a(Jsflagr.Error); + }); - describe('Error', function() { - it('should create an instance of Error', function() { - // uncomment below and update the code to test Error - //var instance = new Jsflagr.Error(); - //expect(instance).to.be.a(Jsflagr.Error); - }); + it('should have the property message (base name: "message")', function() { + // TODO: update the code to test the property message + expect(instance).to.have.property('message'); + // expect(instance.message).to.be(expectedValueLiteral); + }); - it('should have the property message (base name: "message")', function() { - // uncomment below and update the code to test the property message - //var instance = new Jsflagr.Error(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/EvalContext.spec.js b/test/model/EvalContext.spec.js index bdf950f..3962566 100644 --- a/test/model/EvalContext.spec.js +++ b/test/model/EvalContext.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,69 +29,60 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.EvalContext(); - }); + describe('(package)', function() { + describe('EvalContext', function() { + beforeEach(function() { + instance = new Jsflagr.EvalContext(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of EvalContext', function() { + // TODO: update the code to test EvalContext + expect(instance).to.be.a(Jsflagr.EvalContext); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property entityID (base name: "entityID")', function() { + // TODO: update the code to test the property entityID + expect(instance).to.have.property('entityID'); + // expect(instance.entityID).to.be(expectedValueLiteral); + }); - describe('EvalContext', function() { - it('should create an instance of EvalContext', function() { - // uncomment below and update the code to test EvalContext - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be.a(Jsflagr.EvalContext); - }); + it('should have the property entityType (base name: "entityType")', function() { + // TODO: update the code to test the property entityType + expect(instance).to.have.property('entityType'); + // expect(instance.entityType).to.be(expectedValueLiteral); + }); - it('should have the property entityID (base name: "entityID")', function() { - // uncomment below and update the code to test the property entityID - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be(); - }); + it('should have the property entityContext (base name: "entityContext")', function() { + // TODO: update the code to test the property entityContext + expect(instance).to.have.property('entityContext'); + // expect(instance.entityContext).to.be(expectedValueLiteral); + }); - it('should have the property entityType (base name: "entityType")', function() { - // uncomment below and update the code to test the property entityType - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be(); - }); + it('should have the property enableDebug (base name: "enableDebug")', function() { + // TODO: update the code to test the property enableDebug + expect(instance).to.have.property('enableDebug'); + // expect(instance.enableDebug).to.be(expectedValueLiteral); + }); - it('should have the property entityContext (base name: "entityContext")', function() { - // uncomment below and update the code to test the property entityContext - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be(); - }); + it('should have the property flagID (base name: "flagID")', function() { + // TODO: update the code to test the property flagID + expect(instance).to.have.property('flagID'); + // expect(instance.flagID).to.be(expectedValueLiteral); + }); - it('should have the property enableDebug (base name: "enableDebug")', function() { - // uncomment below and update the code to test the property enableDebug - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be(); - }); + it('should have the property flagKey (base name: "flagKey")', function() { + // TODO: update the code to test the property flagKey + expect(instance).to.have.property('flagKey'); + // expect(instance.flagKey).to.be(expectedValueLiteral); + }); - it('should have the property flagID (base name: "flagID")', function() { - // uncomment below and update the code to test the property flagID - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be(); - }); + it('should have the property flagTags (base name: "flagTags")', function() { + // TODO: update the code to test the property flagTags + expect(instance).to.have.property('flagTags'); + // expect(instance.flagTags).to.be(expectedValueLiteral); + }); - it('should have the property flagKey (base name: "flagKey")', function() { - // uncomment below and update the code to test the property flagKey - //var instance = new Jsflagr.EvalContext(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/EvalDebugLog.spec.js b/test/model/EvalDebugLog.spec.js index ae762d6..58e55dd 100644 --- a/test/model/EvalDebugLog.spec.js +++ b/test/model/EvalDebugLog.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,30 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.EvalDebugLog(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + describe('(package)', function() { + describe('EvalDebugLog', function() { + beforeEach(function() { + instance = new Jsflagr.EvalDebugLog(); + }); + + it('should create an instance of EvalDebugLog', function() { + // TODO: update the code to test EvalDebugLog + expect(instance).to.be.a(Jsflagr.EvalDebugLog); + }); + + it('should have the property segmentDebugLogs (base name: "segmentDebugLogs")', function() { + // TODO: update the code to test the property segmentDebugLogs + expect(instance).to.have.property('segmentDebugLogs'); + // expect(instance.segmentDebugLogs).to.be(expectedValueLiteral); + }); + + it('should have the property msg (base name: "msg")', function() { + // TODO: update the code to test the property msg + expect(instance).to.have.property('msg'); + // expect(instance.msg).to.be(expectedValueLiteral); + }); - describe('EvalDebugLog', function() { - it('should create an instance of EvalDebugLog', function() { - // uncomment below and update the code to test EvalDebugLog - //var instance = new Jsflagr.EvalDebugLog(); - //expect(instance).to.be.a(Jsflagr.EvalDebugLog); }); - - it('should have the property segmentDebugLogs (base name: "segmentDebugLogs")', function() { - // uncomment below and update the code to test the property segmentDebugLogs - //var instance = new Jsflagr.EvalDebugLog(); - //expect(instance).to.be(); - }); - - it('should have the property msg (base name: "msg")', function() { - // uncomment below and update the code to test the property msg - //var instance = new Jsflagr.EvalDebugLog(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/EvalResult.spec.js b/test/model/EvalResult.spec.js index 2de5eb1..2ad6440 100644 --- a/test/model/EvalResult.spec.js +++ b/test/model/EvalResult.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,93 +29,78 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.EvalResult(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } - - describe('EvalResult', function() { - it('should create an instance of EvalResult', function() { - // uncomment below and update the code to test EvalResult - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be.a(Jsflagr.EvalResult); - }); - - it('should have the property flagID (base name: "flagID")', function() { - // uncomment below and update the code to test the property flagID - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property flagKey (base name: "flagKey")', function() { - // uncomment below and update the code to test the property flagKey - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property flagSnapshotID (base name: "flagSnapshotID")', function() { - // uncomment below and update the code to test the property flagSnapshotID - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); + describe('(package)', function() { + describe('EvalResult', function() { + beforeEach(function() { + instance = new Jsflagr.EvalResult(); + }); + + it('should create an instance of EvalResult', function() { + // TODO: update the code to test EvalResult + expect(instance).to.be.a(Jsflagr.EvalResult); + }); + + it('should have the property flagID (base name: "flagID")', function() { + // TODO: update the code to test the property flagID + expect(instance).to.have.property('flagID'); + // expect(instance.flagID).to.be(expectedValueLiteral); + }); + + it('should have the property flagKey (base name: "flagKey")', function() { + // TODO: update the code to test the property flagKey + expect(instance).to.have.property('flagKey'); + // expect(instance.flagKey).to.be(expectedValueLiteral); + }); + + it('should have the property flagSnapshotID (base name: "flagSnapshotID")', function() { + // TODO: update the code to test the property flagSnapshotID + expect(instance).to.have.property('flagSnapshotID'); + // expect(instance.flagSnapshotID).to.be(expectedValueLiteral); + }); + + it('should have the property segmentID (base name: "segmentID")', function() { + // TODO: update the code to test the property segmentID + expect(instance).to.have.property('segmentID'); + // expect(instance.segmentID).to.be(expectedValueLiteral); + }); + + it('should have the property variantID (base name: "variantID")', function() { + // TODO: update the code to test the property variantID + expect(instance).to.have.property('variantID'); + // expect(instance.variantID).to.be(expectedValueLiteral); + }); + + it('should have the property variantKey (base name: "variantKey")', function() { + // TODO: update the code to test the property variantKey + expect(instance).to.have.property('variantKey'); + // expect(instance.variantKey).to.be(expectedValueLiteral); + }); + + it('should have the property variantAttachment (base name: "variantAttachment")', function() { + // TODO: update the code to test the property variantAttachment + expect(instance).to.have.property('variantAttachment'); + // expect(instance.variantAttachment).to.be(expectedValueLiteral); + }); + + it('should have the property evalContext (base name: "evalContext")', function() { + // TODO: update the code to test the property evalContext + expect(instance).to.have.property('evalContext'); + // expect(instance.evalContext).to.be(expectedValueLiteral); + }); + + it('should have the property timestamp (base name: "timestamp")', function() { + // TODO: update the code to test the property timestamp + expect(instance).to.have.property('timestamp'); + // expect(instance.timestamp).to.be(expectedValueLiteral); + }); + + it('should have the property evalDebugLog (base name: "evalDebugLog")', function() { + // TODO: update the code to test the property evalDebugLog + expect(instance).to.have.property('evalDebugLog'); + // expect(instance.evalDebugLog).to.be(expectedValueLiteral); + }); - it('should have the property segmentID (base name: "segmentID")', function() { - // uncomment below and update the code to test the property segmentID - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); }); - - it('should have the property variantID (base name: "variantID")', function() { - // uncomment below and update the code to test the property variantID - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property variantKey (base name: "variantKey")', function() { - // uncomment below and update the code to test the property variantKey - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property variantAttachment (base name: "variantAttachment")', function() { - // uncomment below and update the code to test the property variantAttachment - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property evalContext (base name: "evalContext")', function() { - // uncomment below and update the code to test the property evalContext - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property timestamp (base name: "timestamp")', function() { - // uncomment below and update the code to test the property timestamp - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - - it('should have the property evalDebugLog (base name: "evalDebugLog")', function() { - // uncomment below and update the code to test the property evalDebugLog - //var instance = new Jsflagr.EvalResult(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/EvaluationBatchRequest.spec.js b/test/model/EvaluationBatchRequest.spec.js index 839dcc3..d24327d 100644 --- a/test/model/EvaluationBatchRequest.spec.js +++ b/test/model/EvaluationBatchRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,57 +29,48 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.EvaluationBatchRequest(); - }); + describe('(package)', function() { + describe('EvaluationBatchRequest', function() { + beforeEach(function() { + instance = new Jsflagr.EvaluationBatchRequest(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of EvaluationBatchRequest', function() { + // TODO: update the code to test EvaluationBatchRequest + expect(instance).to.be.a(Jsflagr.EvaluationBatchRequest); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property entities (base name: "entities")', function() { + // TODO: update the code to test the property entities + expect(instance).to.have.property('entities'); + // expect(instance.entities).to.be(expectedValueLiteral); + }); - describe('EvaluationBatchRequest', function() { - it('should create an instance of EvaluationBatchRequest', function() { - // uncomment below and update the code to test EvaluationBatchRequest - //var instance = new Jsflagr.EvaluationBatchRequest(); - //expect(instance).to.be.a(Jsflagr.EvaluationBatchRequest); - }); + it('should have the property enableDebug (base name: "enableDebug")', function() { + // TODO: update the code to test the property enableDebug + expect(instance).to.have.property('enableDebug'); + // expect(instance.enableDebug).to.be(expectedValueLiteral); + }); - it('should have the property entities (base name: "entities")', function() { - // uncomment below and update the code to test the property entities - //var instance = new Jsflagr.EvaluationBatchRequest(); - //expect(instance).to.be(); - }); + it('should have the property flagIDs (base name: "flagIDs")', function() { + // TODO: update the code to test the property flagIDs + expect(instance).to.have.property('flagIDs'); + // expect(instance.flagIDs).to.be(expectedValueLiteral); + }); - it('should have the property enableDebug (base name: "enableDebug")', function() { - // uncomment below and update the code to test the property enableDebug - //var instance = new Jsflagr.EvaluationBatchRequest(); - //expect(instance).to.be(); - }); + it('should have the property flagKeys (base name: "flagKeys")', function() { + // TODO: update the code to test the property flagKeys + expect(instance).to.have.property('flagKeys'); + // expect(instance.flagKeys).to.be(expectedValueLiteral); + }); - it('should have the property flagIDs (base name: "flagIDs")', function() { - // uncomment below and update the code to test the property flagIDs - //var instance = new Jsflagr.EvaluationBatchRequest(); - //expect(instance).to.be(); - }); + it('should have the property flagTags (base name: "flagTags")', function() { + // TODO: update the code to test the property flagTags + expect(instance).to.have.property('flagTags'); + // expect(instance.flagTags).to.be(expectedValueLiteral); + }); - it('should have the property flagKeys (base name: "flagKeys")', function() { - // uncomment below and update the code to test the property flagKeys - //var instance = new Jsflagr.EvaluationBatchRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/EvaluationBatchResponse.spec.js b/test/model/EvaluationBatchResponse.spec.js index 9c66d85..d3598b8 100644 --- a/test/model/EvaluationBatchResponse.spec.js +++ b/test/model/EvaluationBatchResponse.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,39 +29,24 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.EvaluationBatchResponse(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('EvaluationBatchResponse', function() { + beforeEach(function() { + instance = new Jsflagr.EvaluationBatchResponse(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of EvaluationBatchResponse', function() { + // TODO: update the code to test EvaluationBatchResponse + expect(instance).to.be.a(Jsflagr.EvaluationBatchResponse); + }); - describe('EvaluationBatchResponse', function() { - it('should create an instance of EvaluationBatchResponse', function() { - // uncomment below and update the code to test EvaluationBatchResponse - //var instance = new Jsflagr.EvaluationBatchResponse(); - //expect(instance).to.be.a(Jsflagr.EvaluationBatchResponse); - }); + it('should have the property evaluationResults (base name: "evaluationResults")', function() { + // TODO: update the code to test the property evaluationResults + expect(instance).to.have.property('evaluationResults'); + // expect(instance.evaluationResults).to.be(expectedValueLiteral); + }); - it('should have the property evaluationResults (base name: "evaluationResults")', function() { - // uncomment below and update the code to test the property evaluationResults - //var instance = new Jsflagr.EvaluationBatchResponse(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/EvaluationEntity.spec.js b/test/model/EvaluationEntity.spec.js index bc851d7..6c46139 100644 --- a/test/model/EvaluationEntity.spec.js +++ b/test/model/EvaluationEntity.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,51 +29,36 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.EvaluationEntity(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('EvaluationEntity', function() { + beforeEach(function() { + instance = new Jsflagr.EvaluationEntity(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of EvaluationEntity', function() { + // TODO: update the code to test EvaluationEntity + expect(instance).to.be.a(Jsflagr.EvaluationEntity); + }); - describe('EvaluationEntity', function() { - it('should create an instance of EvaluationEntity', function() { - // uncomment below and update the code to test EvaluationEntity - //var instance = new Jsflagr.EvaluationEntity(); - //expect(instance).to.be.a(Jsflagr.EvaluationEntity); - }); + it('should have the property entityID (base name: "entityID")', function() { + // TODO: update the code to test the property entityID + expect(instance).to.have.property('entityID'); + // expect(instance.entityID).to.be(expectedValueLiteral); + }); - it('should have the property entityID (base name: "entityID")', function() { - // uncomment below and update the code to test the property entityID - //var instance = new Jsflagr.EvaluationEntity(); - //expect(instance).to.be(); - }); + it('should have the property entityType (base name: "entityType")', function() { + // TODO: update the code to test the property entityType + expect(instance).to.have.property('entityType'); + // expect(instance.entityType).to.be(expectedValueLiteral); + }); - it('should have the property entityType (base name: "entityType")', function() { - // uncomment below and update the code to test the property entityType - //var instance = new Jsflagr.EvaluationEntity(); - //expect(instance).to.be(); - }); + it('should have the property entityContext (base name: "entityContext")', function() { + // TODO: update the code to test the property entityContext + expect(instance).to.have.property('entityContext'); + // expect(instance.entityContext).to.be(expectedValueLiteral); + }); - it('should have the property entityContext (base name: "entityContext")', function() { - // uncomment below and update the code to test the property entityContext - //var instance = new Jsflagr.EvaluationEntity(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/Flag.spec.js b/test/model/Flag.spec.js index 6030590..a7dc9e6 100644 --- a/test/model/Flag.spec.js +++ b/test/model/Flag.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,99 +29,96 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.Flag(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } - - describe('Flag', function() { - it('should create an instance of Flag', function() { - // uncomment below and update the code to test Flag - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be.a(Jsflagr.Flag); - }); - - it('should have the property id (base name: "id")', function() { - // uncomment below and update the code to test the property id - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property key (base name: "key")', function() { - // uncomment below and update the code to test the property key - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property description (base name: "description")', function() { - // uncomment below and update the code to test the property description - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property enabled (base name: "enabled")', function() { - // uncomment below and update the code to test the property enabled - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property segments (base name: "segments")', function() { - // uncomment below and update the code to test the property segments - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property variants (base name: "variants")', function() { - // uncomment below and update the code to test the property variants - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property dataRecordsEnabled (base name: "dataRecordsEnabled")', function() { - // uncomment below and update the code to test the property dataRecordsEnabled - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); + describe('(package)', function() { + describe('Flag', function() { + beforeEach(function() { + instance = new Jsflagr.Flag(); + }); + + it('should create an instance of Flag', function() { + // TODO: update the code to test Flag + expect(instance).to.be.a(Jsflagr.Flag); + }); + + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); + + it('should have the property key (base name: "key")', function() { + // TODO: update the code to test the property key + expect(instance).to.have.property('key'); + // expect(instance.key).to.be(expectedValueLiteral); + }); + + it('should have the property description (base name: "description")', function() { + // TODO: update the code to test the property description + expect(instance).to.have.property('description'); + // expect(instance.description).to.be(expectedValueLiteral); + }); + + it('should have the property enabled (base name: "enabled")', function() { + // TODO: update the code to test the property enabled + expect(instance).to.have.property('enabled'); + // expect(instance.enabled).to.be(expectedValueLiteral); + }); + + it('should have the property tags (base name: "tags")', function() { + // TODO: update the code to test the property tags + expect(instance).to.have.property('tags'); + // expect(instance.tags).to.be(expectedValueLiteral); + }); + + it('should have the property segments (base name: "segments")', function() { + // TODO: update the code to test the property segments + expect(instance).to.have.property('segments'); + // expect(instance.segments).to.be(expectedValueLiteral); + }); + + it('should have the property variants (base name: "variants")', function() { + // TODO: update the code to test the property variants + expect(instance).to.have.property('variants'); + // expect(instance.variants).to.be(expectedValueLiteral); + }); + + it('should have the property dataRecordsEnabled (base name: "dataRecordsEnabled")', function() { + // TODO: update the code to test the property dataRecordsEnabled + expect(instance).to.have.property('dataRecordsEnabled'); + // expect(instance.dataRecordsEnabled).to.be(expectedValueLiteral); + }); + + it('should have the property entityType (base name: "entityType")', function() { + // TODO: update the code to test the property entityType + expect(instance).to.have.property('entityType'); + // expect(instance.entityType).to.be(expectedValueLiteral); + }); + + it('should have the property notes (base name: "notes")', function() { + // TODO: update the code to test the property notes + expect(instance).to.have.property('notes'); + // expect(instance.notes).to.be(expectedValueLiteral); + }); + + it('should have the property createdBy (base name: "createdBy")', function() { + // TODO: update the code to test the property createdBy + expect(instance).to.have.property('createdBy'); + // expect(instance.createdBy).to.be(expectedValueLiteral); + }); + + it('should have the property updatedBy (base name: "updatedBy")', function() { + // TODO: update the code to test the property updatedBy + expect(instance).to.have.property('updatedBy'); + // expect(instance.updatedBy).to.be(expectedValueLiteral); + }); + + it('should have the property updatedAt (base name: "updatedAt")', function() { + // TODO: update the code to test the property updatedAt + expect(instance).to.have.property('updatedAt'); + // expect(instance.updatedAt).to.be(expectedValueLiteral); + }); - it('should have the property entityType (base name: "entityType")', function() { - // uncomment below and update the code to test the property entityType - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); }); - - it('should have the property createdBy (base name: "createdBy")', function() { - // uncomment below and update the code to test the property createdBy - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property updatedBy (base name: "updatedBy")', function() { - // uncomment below and update the code to test the property updatedBy - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - - it('should have the property updatedAt (base name: "updatedAt")', function() { - // uncomment below and update the code to test the property updatedAt - //var instance = new Jsflagr.Flag(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/FlagSnapshot.spec.js b/test/model/FlagSnapshot.spec.js index 3b9a921..773a89f 100644 --- a/test/model/FlagSnapshot.spec.js +++ b/test/model/FlagSnapshot.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,57 +29,42 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.FlagSnapshot(); - }); + describe('(package)', function() { + describe('FlagSnapshot', function() { + beforeEach(function() { + instance = new Jsflagr.FlagSnapshot(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of FlagSnapshot', function() { + // TODO: update the code to test FlagSnapshot + expect(instance).to.be.a(Jsflagr.FlagSnapshot); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); - describe('FlagSnapshot', function() { - it('should create an instance of FlagSnapshot', function() { - // uncomment below and update the code to test FlagSnapshot - //var instance = new Jsflagr.FlagSnapshot(); - //expect(instance).to.be.a(Jsflagr.FlagSnapshot); - }); + it('should have the property updatedBy (base name: "updatedBy")', function() { + // TODO: update the code to test the property updatedBy + expect(instance).to.have.property('updatedBy'); + // expect(instance.updatedBy).to.be(expectedValueLiteral); + }); - it('should have the property id (base name: "id")', function() { - // uncomment below and update the code to test the property id - //var instance = new Jsflagr.FlagSnapshot(); - //expect(instance).to.be(); - }); + it('should have the property flag (base name: "flag")', function() { + // TODO: update the code to test the property flag + expect(instance).to.have.property('flag'); + // expect(instance.flag).to.be(expectedValueLiteral); + }); - it('should have the property updatedBy (base name: "updatedBy")', function() { - // uncomment below and update the code to test the property updatedBy - //var instance = new Jsflagr.FlagSnapshot(); - //expect(instance).to.be(); - }); - - it('should have the property flag (base name: "flag")', function() { - // uncomment below and update the code to test the property flag - //var instance = new Jsflagr.FlagSnapshot(); - //expect(instance).to.be(); - }); + it('should have the property updatedAt (base name: "updatedAt")', function() { + // TODO: update the code to test the property updatedAt + expect(instance).to.have.property('updatedAt'); + // expect(instance.updatedAt).to.be(expectedValueLiteral); + }); - it('should have the property updatedAt (base name: "updatedAt")', function() { - // uncomment below and update the code to test the property updatedAt - //var instance = new Jsflagr.FlagSnapshot(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/Health.spec.js b/test/model/Health.spec.js new file mode 100644 index 0000000..67972cf --- /dev/null +++ b/test/model/Health.spec.js @@ -0,0 +1,52 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. + define(['expect.js', '../../src/index'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + factory(require('expect.js'), require('../../src/index')); + } else { + // Browser globals (root is window) + factory(root.expect, root.Jsflagr); + } +}(this, function(expect, Jsflagr) { + 'use strict'; + + var instance; + + describe('(package)', function() { + describe('Health', function() { + beforeEach(function() { + instance = new Jsflagr.Health(); + }); + + it('should create an instance of Health', function() { + // TODO: update the code to test Health + expect(instance).to.be.a(Jsflagr.Health); + }); + + it('should have the property status (base name: "status")', function() { + // TODO: update the code to test the property status + expect(instance).to.have.property('status'); + // expect(instance.status).to.be(expectedValueLiteral); + }); + + }); + }); + +})); diff --git a/test/model/PutDistributionsRequest.spec.js b/test/model/PutDistributionsRequest.spec.js index e0aea0e..f127283 100644 --- a/test/model/PutDistributionsRequest.spec.js +++ b/test/model/PutDistributionsRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,39 +29,24 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.PutDistributionsRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('PutDistributionsRequest', function() { + beforeEach(function() { + instance = new Jsflagr.PutDistributionsRequest(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of PutDistributionsRequest', function() { + // TODO: update the code to test PutDistributionsRequest + expect(instance).to.be.a(Jsflagr.PutDistributionsRequest); + }); - describe('PutDistributionsRequest', function() { - it('should create an instance of PutDistributionsRequest', function() { - // uncomment below and update the code to test PutDistributionsRequest - //var instance = new Jsflagr.PutDistributionsRequest(); - //expect(instance).to.be.a(Jsflagr.PutDistributionsRequest); - }); + it('should have the property distributions (base name: "distributions")', function() { + // TODO: update the code to test the property distributions + expect(instance).to.have.property('distributions'); + // expect(instance.distributions).to.be(expectedValueLiteral); + }); - it('should have the property distributions (base name: "distributions")', function() { - // uncomment below and update the code to test the property distributions - //var instance = new Jsflagr.PutDistributionsRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/PutFlagRequest.spec.js b/test/model/PutFlagRequest.spec.js index 0eb8fa0..cba92d7 100644 --- a/test/model/PutFlagRequest.spec.js +++ b/test/model/PutFlagRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,63 +29,54 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.PutFlagRequest(); - }); + describe('(package)', function() { + describe('PutFlagRequest', function() { + beforeEach(function() { + instance = new Jsflagr.PutFlagRequest(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of PutFlagRequest', function() { + // TODO: update the code to test PutFlagRequest + expect(instance).to.be.a(Jsflagr.PutFlagRequest); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property description (base name: "description")', function() { + // TODO: update the code to test the property description + expect(instance).to.have.property('description'); + // expect(instance.description).to.be(expectedValueLiteral); + }); - describe('PutFlagRequest', function() { - it('should create an instance of PutFlagRequest', function() { - // uncomment below and update the code to test PutFlagRequest - //var instance = new Jsflagr.PutFlagRequest(); - //expect(instance).to.be.a(Jsflagr.PutFlagRequest); - }); + it('should have the property dataRecordsEnabled (base name: "dataRecordsEnabled")', function() { + // TODO: update the code to test the property dataRecordsEnabled + expect(instance).to.have.property('dataRecordsEnabled'); + // expect(instance.dataRecordsEnabled).to.be(expectedValueLiteral); + }); - it('should have the property description (base name: "description")', function() { - // uncomment below and update the code to test the property description - //var instance = new Jsflagr.PutFlagRequest(); - //expect(instance).to.be(); - }); + it('should have the property entityType (base name: "entityType")', function() { + // TODO: update the code to test the property entityType + expect(instance).to.have.property('entityType'); + // expect(instance.entityType).to.be(expectedValueLiteral); + }); - it('should have the property dataRecordsEnabled (base name: "dataRecordsEnabled")', function() { - // uncomment below and update the code to test the property dataRecordsEnabled - //var instance = new Jsflagr.PutFlagRequest(); - //expect(instance).to.be(); - }); + it('should have the property enabled (base name: "enabled")', function() { + // TODO: update the code to test the property enabled + expect(instance).to.have.property('enabled'); + // expect(instance.enabled).to.be(expectedValueLiteral); + }); - it('should have the property entityType (base name: "entityType")', function() { - // uncomment below and update the code to test the property entityType - //var instance = new Jsflagr.PutFlagRequest(); - //expect(instance).to.be(); - }); + it('should have the property key (base name: "key")', function() { + // TODO: update the code to test the property key + expect(instance).to.have.property('key'); + // expect(instance.key).to.be(expectedValueLiteral); + }); - it('should have the property enabled (base name: "enabled")', function() { - // uncomment below and update the code to test the property enabled - //var instance = new Jsflagr.PutFlagRequest(); - //expect(instance).to.be(); - }); + it('should have the property notes (base name: "notes")', function() { + // TODO: update the code to test the property notes + expect(instance).to.have.property('notes'); + // expect(instance.notes).to.be(expectedValueLiteral); + }); - it('should have the property key (base name: "key")', function() { - // uncomment below and update the code to test the property key - //var instance = new Jsflagr.PutFlagRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/PutSegmentReorderRequest.spec.js b/test/model/PutSegmentReorderRequest.spec.js index f9794c9..2d1918b 100644 --- a/test/model/PutSegmentReorderRequest.spec.js +++ b/test/model/PutSegmentReorderRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,39 +29,24 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.PutSegmentReorderRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('PutSegmentReorderRequest', function() { + beforeEach(function() { + instance = new Jsflagr.PutSegmentReorderRequest(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of PutSegmentReorderRequest', function() { + // TODO: update the code to test PutSegmentReorderRequest + expect(instance).to.be.a(Jsflagr.PutSegmentReorderRequest); + }); - describe('PutSegmentReorderRequest', function() { - it('should create an instance of PutSegmentReorderRequest', function() { - // uncomment below and update the code to test PutSegmentReorderRequest - //var instance = new Jsflagr.PutSegmentReorderRequest(); - //expect(instance).to.be.a(Jsflagr.PutSegmentReorderRequest); - }); + it('should have the property segmentIDs (base name: "segmentIDs")', function() { + // TODO: update the code to test the property segmentIDs + expect(instance).to.have.property('segmentIDs'); + // expect(instance.segmentIDs).to.be(expectedValueLiteral); + }); - it('should have the property segmentIDs (base name: "segmentIDs")', function() { - // uncomment below and update the code to test the property segmentIDs - //var instance = new Jsflagr.PutSegmentReorderRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/PutSegmentRequest.spec.js b/test/model/PutSegmentRequest.spec.js index 149b5ca..43fa167 100644 --- a/test/model/PutSegmentRequest.spec.js +++ b/test/model/PutSegmentRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,30 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.PutSegmentRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + describe('(package)', function() { + describe('PutSegmentRequest', function() { + beforeEach(function() { + instance = new Jsflagr.PutSegmentRequest(); + }); + + it('should create an instance of PutSegmentRequest', function() { + // TODO: update the code to test PutSegmentRequest + expect(instance).to.be.a(Jsflagr.PutSegmentRequest); + }); + + it('should have the property description (base name: "description")', function() { + // TODO: update the code to test the property description + expect(instance).to.have.property('description'); + // expect(instance.description).to.be(expectedValueLiteral); + }); + + it('should have the property rolloutPercent (base name: "rolloutPercent")', function() { + // TODO: update the code to test the property rolloutPercent + expect(instance).to.have.property('rolloutPercent'); + // expect(instance.rolloutPercent).to.be(expectedValueLiteral); + }); - describe('PutSegmentRequest', function() { - it('should create an instance of PutSegmentRequest', function() { - // uncomment below and update the code to test PutSegmentRequest - //var instance = new Jsflagr.PutSegmentRequest(); - //expect(instance).to.be.a(Jsflagr.PutSegmentRequest); }); - - it('should have the property description (base name: "description")', function() { - // uncomment below and update the code to test the property description - //var instance = new Jsflagr.PutSegmentRequest(); - //expect(instance).to.be(); - }); - - it('should have the property rolloutPercent (base name: "rolloutPercent")', function() { - // uncomment below and update the code to test the property rolloutPercent - //var instance = new Jsflagr.PutSegmentRequest(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/PutVariantRequest.spec.js b/test/model/PutVariantRequest.spec.js index 3d555ef..20e3e46 100644 --- a/test/model/PutVariantRequest.spec.js +++ b/test/model/PutVariantRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,30 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.PutVariantRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + describe('(package)', function() { + describe('PutVariantRequest', function() { + beforeEach(function() { + instance = new Jsflagr.PutVariantRequest(); + }); + + it('should create an instance of PutVariantRequest', function() { + // TODO: update the code to test PutVariantRequest + expect(instance).to.be.a(Jsflagr.PutVariantRequest); + }); + + it('should have the property key (base name: "key")', function() { + // TODO: update the code to test the property key + expect(instance).to.have.property('key'); + // expect(instance.key).to.be(expectedValueLiteral); + }); + + it('should have the property attachment (base name: "attachment")', function() { + // TODO: update the code to test the property attachment + expect(instance).to.have.property('attachment'); + // expect(instance.attachment).to.be(expectedValueLiteral); + }); - describe('PutVariantRequest', function() { - it('should create an instance of PutVariantRequest', function() { - // uncomment below and update the code to test PutVariantRequest - //var instance = new Jsflagr.PutVariantRequest(); - //expect(instance).to.be.a(Jsflagr.PutVariantRequest); }); - - it('should have the property key (base name: "key")', function() { - // uncomment below and update the code to test the property key - //var instance = new Jsflagr.PutVariantRequest(); - //expect(instance).to.be(); - }); - - it('should have the property attachment (base name: "attachment")', function() { - // uncomment below and update the code to test the property attachment - //var instance = new Jsflagr.PutVariantRequest(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/Segment.spec.js b/test/model/Segment.spec.js index 47de71e..d765f2f 100644 --- a/test/model/Segment.spec.js +++ b/test/model/Segment.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,69 +29,54 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.Segment(); - }); + describe('(package)', function() { + describe('Segment', function() { + beforeEach(function() { + instance = new Jsflagr.Segment(); + }); - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + it('should create an instance of Segment', function() { + // TODO: update the code to test Segment + expect(instance).to.be.a(Jsflagr.Segment); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); - describe('Segment', function() { - it('should create an instance of Segment', function() { - // uncomment below and update the code to test Segment - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be.a(Jsflagr.Segment); - }); + it('should have the property description (base name: "description")', function() { + // TODO: update the code to test the property description + expect(instance).to.have.property('description'); + // expect(instance.description).to.be(expectedValueLiteral); + }); - it('should have the property id (base name: "id")', function() { - // uncomment below and update the code to test the property id - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be(); - }); + it('should have the property constraints (base name: "constraints")', function() { + // TODO: update the code to test the property constraints + expect(instance).to.have.property('constraints'); + // expect(instance.constraints).to.be(expectedValueLiteral); + }); - it('should have the property description (base name: "description")', function() { - // uncomment below and update the code to test the property description - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be(); - }); + it('should have the property distributions (base name: "distributions")', function() { + // TODO: update the code to test the property distributions + expect(instance).to.have.property('distributions'); + // expect(instance.distributions).to.be(expectedValueLiteral); + }); - it('should have the property constraints (base name: "constraints")', function() { - // uncomment below and update the code to test the property constraints - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be(); - }); + it('should have the property rank (base name: "rank")', function() { + // TODO: update the code to test the property rank + expect(instance).to.have.property('rank'); + // expect(instance.rank).to.be(expectedValueLiteral); + }); - it('should have the property distributions (base name: "distributions")', function() { - // uncomment below and update the code to test the property distributions - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be(); - }); + it('should have the property rolloutPercent (base name: "rolloutPercent")', function() { + // TODO: update the code to test the property rolloutPercent + expect(instance).to.have.property('rolloutPercent'); + // expect(instance.rolloutPercent).to.be(expectedValueLiteral); + }); - it('should have the property rank (base name: "rank")', function() { - // uncomment below and update the code to test the property rank - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be(); }); - - it('should have the property rolloutPercent (base name: "rolloutPercent")', function() { - // uncomment below and update the code to test the property rolloutPercent - //var instance = new Jsflagr.Segment(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/SegmentDebugLog.spec.js b/test/model/SegmentDebugLog.spec.js index 5a47b0c..1e5169e 100644 --- a/test/model/SegmentDebugLog.spec.js +++ b/test/model/SegmentDebugLog.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,45 +29,30 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.SegmentDebugLog(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } - - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + describe('(package)', function() { + describe('SegmentDebugLog', function() { + beforeEach(function() { + instance = new Jsflagr.SegmentDebugLog(); + }); + + it('should create an instance of SegmentDebugLog', function() { + // TODO: update the code to test SegmentDebugLog + expect(instance).to.be.a(Jsflagr.SegmentDebugLog); + }); + + it('should have the property segmentID (base name: "segmentID")', function() { + // TODO: update the code to test the property segmentID + expect(instance).to.have.property('segmentID'); + // expect(instance.segmentID).to.be(expectedValueLiteral); + }); + + it('should have the property msg (base name: "msg")', function() { + // TODO: update the code to test the property msg + expect(instance).to.have.property('msg'); + // expect(instance.msg).to.be(expectedValueLiteral); + }); - describe('SegmentDebugLog', function() { - it('should create an instance of SegmentDebugLog', function() { - // uncomment below and update the code to test SegmentDebugLog - //var instance = new Jsflagr.SegmentDebugLog(); - //expect(instance).to.be.a(Jsflagr.SegmentDebugLog); }); - - it('should have the property segmentID (base name: "segmentID")', function() { - // uncomment below and update the code to test the property segmentID - //var instance = new Jsflagr.SegmentDebugLog(); - //expect(instance).to.be(); - }); - - it('should have the property msg (base name: "msg")', function() { - // uncomment below and update the code to test the property msg - //var instance = new Jsflagr.SegmentDebugLog(); - //expect(instance).to.be(); - }); - }); })); diff --git a/test/model/SetFlagEnabledRequest.spec.js b/test/model/SetFlagEnabledRequest.spec.js index 6fd3c10..205d4c2 100644 --- a/test/model/SetFlagEnabledRequest.spec.js +++ b/test/model/SetFlagEnabledRequest.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,39 +29,24 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.SetFlagEnabledRequest(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('SetFlagEnabledRequest', function() { + beforeEach(function() { + instance = new Jsflagr.SetFlagEnabledRequest(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of SetFlagEnabledRequest', function() { + // TODO: update the code to test SetFlagEnabledRequest + expect(instance).to.be.a(Jsflagr.SetFlagEnabledRequest); + }); - describe('SetFlagEnabledRequest', function() { - it('should create an instance of SetFlagEnabledRequest', function() { - // uncomment below and update the code to test SetFlagEnabledRequest - //var instance = new Jsflagr.SetFlagEnabledRequest(); - //expect(instance).to.be.a(Jsflagr.SetFlagEnabledRequest); - }); + it('should have the property enabled (base name: "enabled")', function() { + // TODO: update the code to test the property enabled + expect(instance).to.have.property('enabled'); + // expect(instance.enabled).to.be(expectedValueLiteral); + }); - it('should have the property enabled (base name: "enabled")', function() { - // uncomment below and update the code to test the property enabled - //var instance = new Jsflagr.SetFlagEnabledRequest(); - //expect(instance).to.be(); }); - }); })); diff --git a/test/model/Tag.spec.js b/test/model/Tag.spec.js new file mode 100644 index 0000000..8357e25 --- /dev/null +++ b/test/model/Tag.spec.js @@ -0,0 +1,58 @@ +/* + * Flagr + * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". + * + * OpenAPI spec version: 1.1.10 + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * + * Swagger Codegen version: 2.4.14 + * + * Do not edit the class manually. + * + */ + +(function(root, factory) { + if (typeof define === 'function' && define.amd) { + // AMD. + define(['expect.js', '../../src/index'], factory); + } else if (typeof module === 'object' && module.exports) { + // CommonJS-like environments that support module.exports, like Node. + factory(require('expect.js'), require('../../src/index')); + } else { + // Browser globals (root is window) + factory(root.expect, root.Jsflagr); + } +}(this, function(expect, Jsflagr) { + 'use strict'; + + var instance; + + describe('(package)', function() { + describe('Tag', function() { + beforeEach(function() { + instance = new Jsflagr.Tag(); + }); + + it('should create an instance of Tag', function() { + // TODO: update the code to test Tag + expect(instance).to.be.a(Jsflagr.Tag); + }); + + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); + + it('should have the property value (base name: "value")', function() { + // TODO: update the code to test the property value + expect(instance).to.have.property('value'); + // expect(instance.value).to.be(expectedValueLiteral); + }); + + }); + }); + +})); diff --git a/test/model/Variant.spec.js b/test/model/Variant.spec.js index 4594116..e07f5b3 100644 --- a/test/model/Variant.spec.js +++ b/test/model/Variant.spec.js @@ -1,13 +1,13 @@ -/** +/* * Flagr * Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is \"/api/v1\". * - * OpenAPI spec version: 1.1.0 + * OpenAPI spec version: 1.1.10 * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * - * Swagger Codegen version: 2.4.0-SNAPSHOT + * Swagger Codegen version: 2.4.14 * * Do not edit the class manually. * @@ -29,51 +29,36 @@ var instance; - beforeEach(function() { - instance = new Jsflagr.Variant(); - }); - - var getProperty = function(object, getter, property) { - // Use getter method if present; otherwise, get the property directly. - if (typeof object[getter] === 'function') - return object[getter](); - else - return object[property]; - } + describe('(package)', function() { + describe('Variant', function() { + beforeEach(function() { + instance = new Jsflagr.Variant(); + }); - var setProperty = function(object, setter, property, value) { - // Use setter method if present; otherwise, set the property directly. - if (typeof object[setter] === 'function') - object[setter](value); - else - object[property] = value; - } + it('should create an instance of Variant', function() { + // TODO: update the code to test Variant + expect(instance).to.be.a(Jsflagr.Variant); + }); - describe('Variant', function() { - it('should create an instance of Variant', function() { - // uncomment below and update the code to test Variant - //var instance = new Jsflagr.Variant(); - //expect(instance).to.be.a(Jsflagr.Variant); - }); + it('should have the property id (base name: "id")', function() { + // TODO: update the code to test the property id + expect(instance).to.have.property('id'); + // expect(instance.id).to.be(expectedValueLiteral); + }); - it('should have the property id (base name: "id")', function() { - // uncomment below and update the code to test the property id - //var instance = new Jsflagr.Variant(); - //expect(instance).to.be(); - }); + it('should have the property key (base name: "key")', function() { + // TODO: update the code to test the property key + expect(instance).to.have.property('key'); + // expect(instance.key).to.be(expectedValueLiteral); + }); - it('should have the property key (base name: "key")', function() { - // uncomment below and update the code to test the property key - //var instance = new Jsflagr.Variant(); - //expect(instance).to.be(); - }); + it('should have the property attachment (base name: "attachment")', function() { + // TODO: update the code to test the property attachment + expect(instance).to.have.property('attachment'); + // expect(instance.attachment).to.be(expectedValueLiteral); + }); - it('should have the property attachment (base name: "attachment")', function() { - // uncomment below and update the code to test the property attachment - //var instance = new Jsflagr.Variant(); - //expect(instance).to.be(); }); - }); }));