173 of 215 branches covered (80.47%)
Branch coverage included in aggregate %.
1923 of 2111 new or added lines in 56 files covered. (91.09%)
4 existing lines in 1 file now uncovered.3277 of 3528 relevant lines covered (92.89%)
5.88 hits per line
NEW
|
export const checkServerConnection = async (): Promise<boolean> => { |
|
NEW
|
const port = process.env.PORT || 5173; |
× |
NEW
|
try {
|
× |
NEW
|
const response = await fetch(`http://localhost:${port}/`); |
× |
NEW
|
if (response.status !== 200) return false; |
× |
NEW
|
return true; |
× |
NEW
|
} catch (error) {
|
× |
NEW
|
return false; |
× |
NEW
|
} |
× |
NEW
|
}; |
× |