import { describe, it, expect, beforeEach } from 'vitest';
import Calculator from './calculator';

describe('Calculator', () => {
  let calculator: Calculator;
  beforeEach(() => {
    calculator = new Calculator();
  });

  describe('add', () => {
    it('should add 1 and 1 and return 2', () => {
      const result = calculator.add(1, 1);
      expect(result).toBe(2);
    });

    it('should add -1 and 1 and return 0', () => {
      const result = calculator.add(-1, 1);
      expect(result).toBe(0);
    });
  });
});
