<commit_before>
import * as restHalTestTools from "@zephyrec/rest-hal-test-tools";

import ava from "ava";
import * as express from "express";
import * as superTest from "supertest";

import * as rootResourceController from "./root-resource";

ava.beforeEach((t) => {
  const app = express();
  const models = ["a", "b", "c"];
  const controller = new rootResourceController.RootResourceController(models);

  controller.setUpRoute(app.route("/"));

  t.context.agent = superTest(app);
  t.context.resource = "/";
  t.context.models = models;
});

ava(restHalTestTools.resourceImplementOPTIONSMethod);
ava(restHalTestTools.resourceOPTIONSMethodAllowGET);
ava(restHalTestTools.resourceImplementGETMethod);<commit_msg>Added a new test to the root-resource controller test suite<commit_after>
import * as restHalTestTools from "@zephyrec/rest-hal-test-tools";

import ava from "ava";
import * as express from "express";
import * as superTest from "supertest";

import * as rootResourceController from "./root-resource";

ava.beforeEach((t) => {
  const app = express();
  const models = ["a", "b", "c"];
  const controller = new rootResourceController.RootResourceController(models);

  controller.setUpRoute(app.route("/"));

  t.context.agent = superTest(app);
  t.context.resource = "/";
  t.context.models = models;
});

ava(restHalTestTools.resourceImplementOPTIONSMethod);
ava(restHalTestTools.resourceOPTIONSMethodAllowGET);
ava(restHalTestTools.resourceImplementGETMethod);
ava(restHalTestTools.resourceGETMethodImplementServerDrivenContentNegotiation);
{'fraction_non_alphanumeric': 0.13157894736842105, 'fraction_numerical': 0.0, 'mean_word_length': 6.184331797235023, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5433428', 'n_tokens_mistral': 462, 'n_tokens_neox': 461, 'n_words': 103}