Merge pull request #17248 from webpack/issue-17189

test: case for destruction
This commit is contained in:
Sean Larkin 2023-05-24 07:21:59 -07:00 committed by GitHub
commit d802b28b66
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,15 @@
import module from "./module.js";
it("should parse sparse arrays", function() {
var {
a,
...other1
} = module;
var {
b,
...other2
} = module;
expect(other1).toEqual({ b: 2, c: 3 });
expect(other2).toEqual({ a: 1, c: 3 });
});

View File

@ -0,0 +1,6 @@
var test = {
a: 1,
b: 2,
c: 3
};
export default test;