concept content in category microservice

appears as: content, contents, The contents, content
Testing Microservices with Mountebank

This is an excerpt from Manning's book Testing Microservices with Mountebank.

Listing 2.7. Creating the content imposter
var contentPort = 4000;

function createContentImposter() {
  return imposter({
      port: contentPort,
      protocol: "http",
      name: "Content Service"
    })
    .withStub()
    .matchingRequest({
      equals: {                                             #1
        path: "/content",                                   #1
        query: { ids: "2599b7f4,e1977c9e" }                 #1
      }                                                     #1
    })
    .respondingWith({
      statusCode: 200,
      headers: {"Content-Type": "application/json"},
      body: {
        content: [                                          #2
          {                                                 #2
            id: "2599b7f4",                                 #2
            copy: "Treat your dog like the king he is",     #2
            image: "/content/c5b221e2"                      #2
          },                                                #2
          {                                                 #2
            id: "e1977c9e",                                 #2
            copy: "Love your fish; they'll love you back",  #2
            image: "/content/a0fad9fb"                      #2
          }                                                 #2
        ]                                                   #2
      }
    })
    .create();
}
Testing Java Microservices: Using Arquillian, Hoverfly, AssertJ, JUnit, Selenium, and Mockito

This is an excerpt from Manning's book Testing Java Microservices: Using Arquillian, Hoverfly, AssertJ, JUnit, Selenium, and Mockito.

YouTube is a global video-sharing website. You can add YouTube functionality to any site and even search for content.

All you need to do to create a different kind of archive is pass the subclass of Archive you wish to create in the method. When a more specific subtype is used, many more options are available for adding content to the archive.