173 of 215 branches covered (80.47%)
Branch coverage included in aggregate %.
1922 of 2110 new or added lines in 56 files covered. (91.09%)
4 existing lines in 1 file now uncovered.3276 of 3527 relevant lines covered (92.88%)
5.89 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
|
}; |
× |