Skip to content

Commit

Permalink
Add test comments
Browse files Browse the repository at this point in the history
  • Loading branch information
BPapp-MS committed Apr 11, 2024
1 parent 683cac9 commit 562ad40
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ const graphParser: GraphParser = new GraphParser({
terminal: { writeErrorLine: jest.fn(), writeLine: jest.fn() }
} as unknown as ILogger);

// This checks the test repo output to ensure that the command succeeds and the graph is built correctly
describe('--drop-graph integration process', () => {
beforeAll(async () => {
if (procOut.error) {
Expand All @@ -54,6 +55,7 @@ describe('--drop-graph integration process', () => {
});
});

// These run unit tests on the checked in test-operation-map.json file, which mimics what rush passes in
describe(GraphParser.name, () => {
it('should fail if the input schema is invalid', () => {
const operations = JSON.parse(JSON.stringify(testData.OperationMap));
Expand All @@ -77,6 +79,7 @@ describe(GraphParser.name, () => {
});
});

// These check the graph.json file that was generated by the integration test and unit tests the validator on it
describe('validateGraph', () => {
it('should validate graph.json', () => {
const isValid: boolean = graphParser.validateGraph(exampleGraph);
Expand Down

0 comments on commit 562ad40

Please sign in to comment.