Skip to content

Commit

Permalink
test(typings): Add langfile (msg) import + typings test
Browse files Browse the repository at this point in the history
  • Loading branch information
cpcallen committed Mar 21, 2024
1 parent 5462b21 commit 8dc73b7
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions tests/typescript/src/msg.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* @license
* Copyright 2022 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/

/**
* Test: Should be able to import messages and verify their type.
* Test at least one language other than English!
*/

import * as en from 'blockly-test/msg/en';
import * as fr from 'blockly-test/msg/fr';

let msg: {[key: string]: string};
msg = fr;
msg = en;

// Satisfy eslint that msg is used.
console.log(msg['DIALOG_OK']);

0 comments on commit 8dc73b7

Please sign in to comment.