Files
freeCodeCamp/client/i18n/motivation-schema.js
Tom 3978c6be28 feat: i18n user interface (#40306)
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-01-31 12:15:32 +05:30

23 lines
530 B
JavaScript

/* eslint-disable camelcase */
/* This is used for testing to make sure the motivation.json files
* in each language have the correct structure
*/
const {
arrayOfItems,
strictObject,
stringType
} = require('jest-json-schema-extended');
const motivationSchema = strictObject({
compliments: arrayOfItems(stringType, { minItems: 1 }),
motivationalQuotes: arrayOfItems(
strictObject({
quote: stringType,
author: stringType
}),
{ minItems: 1 }
)
});
exports.motivationSchema = motivationSchema;