Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

expect-expect doesn't accept assert #502

Closed
fregante opened this issue Aug 13, 2024 · 3 comments · Fixed by #504 or #508
Closed

expect-expect doesn't accept assert #502

fregante opened this issue Aug 13, 2024 · 3 comments · Fixed by #504 or #508

Comments

@fregante
Copy link

assert is a first-class tester in Vitest: https://vitest.dev/api/assert

The rule seems to only focus on expect but it doesn't need to be. Tests are valid as long as they test something, regardless of how they do that.

@veritem
Copy link
Member

veritem commented Aug 14, 2024

fixed in #504

@veritem veritem closed this as completed Aug 14, 2024
@fregante
Copy link
Author

I'm still seeing the issue in v1.0.2

test('cleanPrCommitTitle', () => {
	const clean = 'Something done';
	assert.equal(cleanPrCommitTitle('Something done (#123)', 123), clean);
	assert.equal(cleanPrCommitTitle('  Something done  (#123)  ', 123), clean);
	assert.equal(cleanPrCommitTitle(' Something done ', 123), clean);

	assert.notEqual(cleanPrCommitTitle('Something done (fixes #123)', 123), clean);
	assert.notEqual(cleanPrCommitTitle('Something done (#23454)', 123), clean);
});
Screenshot 1

@veritem
Copy link
Member

veritem commented Aug 14, 2024

i'll investigate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants