Fix TypeScript compilation error: remove duplicate 'default' property… #249
beta-release.yml
on: push
Matrix: build_and_test / build
Discord Webhooks
/
github-releases-to-discord
5s
pre-release
/
Create New Github Beta Pre Release
6s
Annotations
1 warning and 1 notice
|
Discord Webhooks / github-releases-to-discord
embed field value must be shorter than 1024, got 1482
[`a5aaefc`](https://github.com/homebridge-plugins/homebridge-august/commit/a5aaefc99b94299a0d9e9b970e0c329b33a1cfed) Fix TypeScript compilation error: remove duplicate 'default' property in august-yale mock (#172)
Fixes a TypeScript compilation error in `src/platform.test.ts` where the
august-yale module mock had duplicate `default` properties in the same
object literal:
```typescript
// Before (compilation error)
return {
default: class August { ... }, // First default property
default: MockConstructor, // Second default property - DUPLICATE!
}
// After (fixed)
return {
default: MockConstructor,
}
```
The error was:
```
src/platform.test.ts:35:5 - error TS1117: An object literal cannot have multiple properties with the same name.
```
The fix removes the redundant class definition and keeps only the
`MockConstructor` as the default export, which already provides all the
necessary static methods (`authorize`, `validate`, `details`) for
testing. All existing tests continue to pass.
Fixes #171.
<!-- START COPILOT CODING AGENT TIPS -->
---
💬 Share your feedback on Copilot coding agent for the chance to win a
$200 gift card! Click
[here](https://survey3.medallia.com/?EAHeSx-AP01bZqG0Ld9QLQ) to start
the survey.
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: Donavan Becker <[email protected]>
Co-authored-by: donavanbecker <[email protected]>
|
|
publish / publish_npm
Published on NPM - 3.0.3-beta.8
|