-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Write tests cleanup #167
Write tests cleanup #167
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -20,7 +20,7 @@ describe(`operations.write`, () => { | |||
} | |||
}`); | |||
|
|||
describe(`invalid write on a root, expect an object`, () => { | |||
describe(`invalid nested values, expect an object`, () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"expect an object" is still a verb phrase - maybe "scalar in place of object value"?
@@ -23,7 +23,7 @@ describe(`operations.write`, () => { | |||
} | |||
}`); | |||
|
|||
describe(`write to inner nodes`, () => { | |||
describe(`updates inner nodes`, () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"inner node updates"? maybe
…licate references" and rename files
Part of #136. This PR is best reviewed by commit as each commit is equal to an update of the folder.
What happen in this PR are:
simplifying
describe
clause. We only have two layers of describe clauses - one for specifying the tested operation such as write, read etc. the other is a test scenario itself.rename file to have better name
Some guidelines I try to stick with:
describe
description is to describe scenario, majority are just type of payload or query.without verb to describe an act, we assume tests are just doing write operation.
If tests do more than just write, use verb to specify such action in the
describe
description such as "updates" etc.anything that is an entity in the system is referred as
references
asentity
will be represent as reference off a root queryanything that is non-entity is referred as
values
All setup should be in
beforeAll
clause;it
clause should just do the test