Move to protobufjs in ts/groups.ts
This commit is contained in:
parent
972a4cba0c
commit
9f0c630574
30 changed files with 1424 additions and 964 deletions
19
ts/test-both/util/dropNull_test.ts
Normal file
19
ts/test-both/util/dropNull_test.ts
Normal file
|
@ -0,0 +1,19 @@
|
|||
// Copyright 2021 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
import { assert } from 'chai';
|
||||
|
||||
import { dropNull } from '../../util/dropNull';
|
||||
|
||||
describe('dropNull', () => {
|
||||
it('swaps null with undefined', () => {
|
||||
assert.strictEqual(dropNull(null), undefined);
|
||||
});
|
||||
|
||||
it('leaves undefined be', () => {
|
||||
assert.strictEqual(dropNull(undefined), undefined);
|
||||
});
|
||||
|
||||
it('non-null values undefined be', () => {
|
||||
assert.strictEqual(dropNull('test'), 'test');
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue