Skip to content

Commit

Permalink
test: add staging cases
Browse files Browse the repository at this point in the history
  • Loading branch information
sor4chi committed Oct 30, 2024
1 parent dd8be57 commit a8fcb23
Showing 1 changed file with 46 additions and 0 deletions.
46 changes: 46 additions & 0 deletions checker/specification/staging.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,49 @@
Currently implementing:

> This file is for work-in-progress and can help separating features that are being implemented to regressions
### Feats

#### `Object.freeze`

> When `Object.freeze` is called, the object's `isSealed` is inferred as `true`
```ts
const obj = {}
let result = Object.freeze(obj);
(obj === result) satisfies true;
obj.property = 2;
Object.isSealed(obj) satisfies true;
```

- Cannot write to property 'property'

#### `Object.seal`

> When `Object.seal` is called, the object's `isFrozen` and `isSealed` are inferred as `true`
```ts
const obj = {}
let result = Object.seal(obj);
(obj === result) satisfies true;
obj.property = 2;
Object.isFrozen(obj) satisfies true;
Object.isSealed(obj) satisfies true;
```

- Cannot write to property 'property'

#### `Object.preventExtensions`

> When `Object.preventExtensions` is called, the object's `isFrozen` and `isSealed` are inferred as `true`
```ts
const obj = {}
let result = Object.preventExtensions(obj);
(obj === result) satisfies true;
obj.property = 2;
Object.isFrozen(obj) satisfies true;
Object.isSealed(obj) satisfies true;
```

- Cannot write to property 'property'

0 comments on commit a8fcb23

Please sign in to comment.