message: organizing tests
diff: @@ -60,7 +60,8 @@ describe('writer', function() {
  await temp.cleanup();
  });
  - it('saves attributes when creating a record', async function () {
  + describe('create', function() {
  + it('saves attributes', async function () {
  let record = await writer.create('master', user, 'articles', {
  type: 'articles',
  attributes: {
  @@ -73,7 +74,7 @@ describe('writer', function() {
  });
  });
  - it('returns correct document when creating a record', async function () {
  + it('returns correct document', async function () {
  let record = await writer.create('master', user, 'articles', {
  type: 'articles',
  attributes: {
  @@ -139,7 +140,7 @@ describe('writer', function() {
  }
  });
  - it('requires type in body during create', async function() {
  + it('requires type in body', async function() {
  try {
  await writer.create('master', user, 'articles', {
  id: '1',
  @@ -158,7 +159,7 @@ describe('writer', function() {
  }
  });
  - it('rejects mismatched type during create', async function() {
  + it('rejects mismatched type', async function() {
  try {
  await writer.create('master', user, 'articles', {
  id: '1',
  @@ -177,8 +178,11 @@ describe('writer', function() {
  expect(err.source).to.deep.equal({ pointer: '/data/type' });
  }
  });
  + });
  +
  + describe('update', function() {
  - it('requires id in body during update', async function() {
  + it('requires id in body', async function() {
  try {
  await writer.update('master', user, 'articles', '1', {
  type: 'articles',
  @@ -197,7 +201,7 @@ describe('writer', function() {
  }
  });
  - it('requires type in body during update', async function() {
  + it('requires type in body', async function() {
  try {
  await writer.update('master', user, 'articles', '1', {
  id: '1',
  @@ -219,7 +223,7 @@ describe('writer', function() {
  }
  });
  - it('rejects mismatched type during update', async function() {
  + it('rejects mismatched type', async function() {
  try {
  await writer.update('master', user, 'articles', '1', {
  id: '1',
  @@ -347,7 +351,7 @@ describe('writer', function() {
  .property('title', 'Updated title');
  });
  - it('reports merge conflict during update', async function() {
  + it('reports merge conflict', async function() {
  await writer.update('master', user, 'articles', '1', {
  id: '1',
  type: 'articles',
  @@ -379,5 +383,5 @@ describe('writer', function() {
  expect(err.detail).to.match(/merge conflict/i);
  }
  });
  -
  + });
  });
  