Skip to content

Commit

Permalink
Create education.test.js
Browse files Browse the repository at this point in the history
  • Loading branch information
KOSASIH authored Dec 3, 2024
1 parent 80b2f6a commit fb1a2b0
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions tests/education.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// tests/education.test.js
const Education = require('../education'); // Assuming you have an education module

describe('Education Module', () => {
let education;

beforeEach(() => {
education = new Education();
});

test('should add a new course correctly', () => {
education.addCourse('JavaScript Basics');
expect(education.getCourses()).toContain('JavaScript Basics');
});

test('should remove a course correctly', () => {
education.addCourse('JavaScript Basics');
education.removeCourse('JavaScript Basics');
expect(education.getCourses()).not.toContain('JavaScript Basics');
});
});

0 comments on commit fb1a2b0

Please sign in to comment.