11'use strict' ;
22
33import assert from 'assert' ;
4+ import ftl from "@fluent/dedent" ;
45
56import FluentBundle from '../src/bundle' ;
67import FluentResource from '../src/resource' ;
7- import { ftl } from '../src/util' ;
88
99suite ( 'Bundle' , function ( ) {
1010 let bundle , args , errs ;
@@ -19,7 +19,7 @@ suite('Bundle', function() {
1919 bundle . addMessages ( ftl `
2020 foo = Foo
2121 -bar = Private Bar
22- ` ) ;
22+ ` ) ;
2323 } ) ;
2424
2525 test ( 'adds messages' , function ( ) {
@@ -32,7 +32,7 @@ suite('Bundle', function() {
3232 test ( 'preserves existing messages when new are added' , function ( ) {
3333 bundle . addMessages ( ftl `
3434 baz = Baz
35- ` ) ;
35+ ` ) ;
3636
3737 assert . equal ( bundle . _messages . has ( 'foo' ) , true ) ;
3838 assert . equal ( bundle . _terms . has ( 'foo' ) , false ) ;
@@ -46,7 +46,7 @@ suite('Bundle', function() {
4646 test ( 'messages and terms can share the same name' , function ( ) {
4747 bundle . addMessages ( ftl `
4848 -foo = Private Foo
49- ` ) ;
49+ ` ) ;
5050 assert . equal ( bundle . _messages . has ( 'foo' ) , true ) ;
5151 assert . equal ( bundle . _terms . has ( 'foo' ) , false ) ;
5252 assert . equal ( bundle . _messages . has ( '-foo' ) , false ) ;
@@ -57,7 +57,7 @@ suite('Bundle', function() {
5757 test ( 'does not overwrite existing messages if the ids are the same' , function ( ) {
5858 const errors = bundle . addMessages ( ftl `
5959 foo = New Foo
60- ` ) ;
60+ ` ) ;
6161
6262 // Attempt to overwrite error reported
6363 assert . equal ( errors . length , 1 ) ;
@@ -73,7 +73,7 @@ suite('Bundle', function() {
7373 test ( 'overwrites existing messages if the ids are the same and allowOverrides is true' , function ( ) {
7474 const errors = bundle . addMessages ( ftl `
7575 foo = New Foo
76- ` , { allowOverrides : true } ) ;
76+ ` , { allowOverrides : true } ) ;
7777
7878 // No overwrite errors reported
7979 assert . equal ( errors . length , 0 ) ;
@@ -93,7 +93,7 @@ suite('Bundle', function() {
9393 let resource = FluentResource . fromString ( ftl `
9494 foo = Foo
9595 -bar = Bar
96- ` ) ;
96+ ` ) ;
9797 bundle . addResource ( resource ) ;
9898 } ) ;
9999
@@ -149,7 +149,7 @@ suite('Bundle', function() {
149149 err4 =
150150 .attr1 = Attr
151151 .attr2 = {}
152- ` ) ;
152+ ` ) ;
153153 } ) ;
154154
155155 test ( 'returns true only for public messages' , function ( ) {
@@ -176,7 +176,7 @@ suite('Bundle', function() {
176176 bundle . addMessages ( ftl `
177177 foo = Foo
178178 -bar = Bar
179- ` ) ;
179+ ` ) ;
180180 } ) ;
181181
182182 test ( 'returns public messages' , function ( ) {
0 commit comments