Comparing version 1.0.32 to 1.0.34
{ | ||
"name": "meadow", | ||
"version": "1.0.32", | ||
"version": "1.0.34", | ||
"description": "A data access library.", | ||
@@ -11,4 +11,4 @@ "main": "source/Meadow.js", | ||
"tests": "./node_modules/mocha/bin/_mocha -u tdd -R spec --grep", | ||
"doc": "./node_modules/groc/bin/groc --index-page-title Overview ./README.md ./source/**/*.js ./source/*.js", | ||
"doc-stage-retold": "./node_modules/groc/bin/groc --index-page-title Overview -o ../retold/meadow ./README.md ./source/**/*.js ./source/*.js" | ||
"docker-dev-build-image": "docker build ./ -t retold/meadow:local", | ||
"docker-dev-run": "docker run -it -d --name meadow-dev -p 127.0.0.1:12342:8080 -p 12106:3306 -v \"$PWD/.config:/home/coder/.config\" -v \"$PWD:/home/coder/meadow\" -u \"$(id -u):$(id -g)\" -e \"DOCKER_USER=$USER\" retold/meadow:local" | ||
}, | ||
@@ -42,3 +42,3 @@ "repository": { | ||
"fable": "~1.0.1", | ||
"foxhound": "~1.0.34", | ||
"foxhound": "^1.0.37", | ||
"is-my-json-valid": "2.16.0", | ||
@@ -45,0 +45,0 @@ "underscore": "1.8.3" |
@@ -124,2 +124,22 @@ Meadow | ||
); | ||
``` | ||
``` | ||
### Docker Development Environment | ||
1. Run this command to build this image: | ||
``` | ||
docker build ./ -t retold/meadow:local | ||
``` | ||
2. Run this command to build the local container: | ||
``` | ||
docker run -it --name meadow-dev -p 127.0.0.1:12342:8080 -v "$PWD/.config:/home/coder/.config" -v "$PWD:/home/coder/meadow" -u "$(id -u):$(id -g)" -e "DOCKER_USER=$USER" retold/meadow:local | ||
``` | ||
3. Go to http://localhost:12342/ in a web browser | ||
4. The password is "retold" | ||
5. Right now you (may) need to delete the `node_modules` folders and regenerate it for Linux. |
@@ -64,3 +64,3 @@ // ##### Part of the **[retold](https://stevenvelozo.github.io/retold/)** system | ||
*/ | ||
var _MeadowPackageLoader = require('./Meadow-PackageLoader.js'); | ||
var _MeadowPackageLoader = require('./Meadow-PackageFileLoader.js'); | ||
var loadFromPackage = function(pPackage) | ||
@@ -71,4 +71,12 @@ { | ||
/** | ||
* Load a Meadow Package JSON from file, create a Meadow object from it. | ||
*/ | ||
var _MeadowPackageObjectLoader = require('./Meadow-PackageObjectLoader.js'); | ||
var loadFromPackageObject = function(pPackage) | ||
{ | ||
return _MeadowPackageObjectLoader(this, pPackage); | ||
}; | ||
/** | ||
* Pass relevant state into the provider | ||
@@ -372,2 +380,3 @@ * | ||
loadFromPackage: loadFromPackage, | ||
loadFromPackageObject: loadFromPackageObject, | ||
setScope: setScope, | ||
@@ -374,0 +383,0 @@ setDomain: setDomain, |
@@ -220,2 +220,59 @@ /** | ||
( | ||
'Try to load from a json object', | ||
function() | ||
{ | ||
var testMeadow = require('../source/Meadow.js').new(_Fable).loadFromPackageObject( | ||
{ | ||
"Scope": "MyPackage", | ||
"DefaultIdentifier": "IDMyPackage", | ||
"Schema": [ | ||
{ "Column": "IDMyPackage", "Type":"AutoIdentity" }, | ||
{ "Column": "GUIDMyPackage", "Type":"AutoGUID" }, | ||
{ "Column": "Name", "Type":"String" }, | ||
{ "Column": "Age", "Type":"Number" } | ||
], | ||
"DefaultObject": { | ||
"IDMyPackage": 0, | ||
"GUIDMyPackage": "0000-0000", | ||
"Name": "Unknown", | ||
"Age": 0 | ||
}, | ||
"JsonSchema": { | ||
"title": "MyPackage", | ||
"description": "A nondescript package.", | ||
"type": "object", | ||
"properties": { | ||
"IDMyPackage": { | ||
"description": "The unique identifier for our package", | ||
"type": "integer" | ||
}, | ||
"GUIDMyPackage": { | ||
"description": "A string UUID for our package", | ||
"type": "string" | ||
}, | ||
"Name": { | ||
"description": "The name", | ||
"type": "string" | ||
}, | ||
"Age": { | ||
"description": "How old the package is", | ||
"type": "number", | ||
"minimum": 0, | ||
"exclusiveMinimum": true | ||
} | ||
}, | ||
"required": ["IDMyPackage", "Name"] | ||
} | ||
}); | ||
Expect(testMeadow.scope) | ||
.to.equal('MyPackage'); | ||
} | ||
) | ||
test | ||
( | ||
'Try to load from an empty json package', | ||
@@ -222,0 +279,0 @@ function() |
@@ -26,3 +26,3 @@ /** | ||
User: "root", | ||
Password: "", | ||
Password: "123456789", | ||
Database: "FableTest", | ||
@@ -1120,2 +1120,2 @@ ConnectionPoolLimit: 20 | ||
} | ||
); | ||
); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
391143
95
11062
144
Updatedfoxhound@^1.0.37