Files
KQL ce6aa207e9 fix: 修复图片路径以适配GitHub Pages base path
- 将所有图片路径从绝对路径改为使用 process.env.PUBLIC_URL
- 修复 HomePage.tsx 中所有图片引用
- 修复 CoursePage.tsx 中所有图片引用
- 确保图片在 GitHub Pages 上正确加载

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-04 09:24:45 +08:00

1.2 KiB

Disallow Jasmine globals (no-jasmine-globals)

jest uses jasmine as a test runner. A side effect of this is that both a jasmine object, and some jasmine-specific globals, are exposed to the test environment. Most functionality offered by Jasmine has been ported to Jest, and the Jasmine globals will stop working in the future. Developers should therefore migrate to Jest's documented API instead of relying on the undocumented Jasmine API.

Rule details

This rule reports on any usage of Jasmine globals which is not ported to Jest, and suggests alternative from Jest's own API.

Default configuration

The following patterns are considered warnings:

jasmine.DEFAULT_TIMEOUT_INTERVAL = 5000;

test('my test', () => {
  pending();
});

test('my test', () => {
  fail();
});

test('my test', () => {
  spyOn(some, 'object');
});

test('my test', () => {
  jasmine.createSpy();
});

test('my test', () => {
  expect('foo').toEqual(jasmine.anything());
});

The following patterns would not be considered warnings:

jest.setTimeout(5000);

test('my test', () => {
  jest.spyOn(some, 'object');
});

test('my test', () => {
  jest.fn();
});

test('my test', () => {
  expect('foo').toEqual(expect.anything());
});