Created
August 10, 2017 03:47
-
-
Save haltcase/23280b08fbd2171c2072cdd50bfae262 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://travis-ci.org/citycide/trilogy/jobs/262847143 | |
// https://github.com/citycide/trilogy/blob/92bfe9e2c0767ab1f489b2cb66446d979e0c6726/tests/getter-setter.js | |
// results in: SyntaxError { 'Unexpected token (' } | |
test.before(async () => { | |
await db.model('people', { | |
name: { | |
type: String, | |
// renaming this to `get` prevents the error | |
getter: name => name.toUpperCase() | |
}, | |
age: { | |
type: Number, | |
// renaming this to `set` prevents the error | |
setter: age => age + 1 | |
} | |
}) | |
return db.create('people', { | |
name: 'Joey Smith', | |
age: 20 | |
}) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Here's the compiled version of that piece that AVA caches and runs: