@@ -350,16 +350,17 @@ describe('CLI Workflow E2E', () => {
350350 // Ignore if already cleared
351351 }
352352
353+ expect . assertions ( 1 ) ;
353354 try {
354355 runCLI ( 'deepl glossary languages' ) ;
355- expect ( true ) . toBe ( true ) ;
356356 } catch ( error : any ) {
357357 const output = error . stderr ?? error . stdout ?? error . message ;
358358 expect ( output ) . toMatch ( / A P I k e y | a u t h / i) ;
359359 }
360360 } ) ;
361361
362362 it ( 'should not require any arguments' , ( ) => {
363+ expect . assertions ( 2 ) ;
363364 try {
364365 // Will fail without API key but should not require arguments
365366 runCLI ( 'deepl glossary languages' ) ;
@@ -379,9 +380,9 @@ describe('CLI Workflow E2E', () => {
379380 // Ignore if already cleared
380381 }
381382
383+ expect . assertions ( 1 ) ;
382384 try {
383385 runCLI ( 'deepl glossary languages' ) ;
384- expect ( true ) . toBe ( true ) ;
385386 } catch ( error : any ) {
386387 // Non-zero exit code
387388 expect ( error . status ) . toBeGreaterThan ( 0 ) ;
@@ -760,9 +761,9 @@ describe('CLI Workflow E2E', () => {
760761 } ) ;
761762
762763 it ( 'should require API key for style-rules list' , ( ) => {
764+ expect . assertions ( 1 ) ;
763765 try {
764766 runCLI ( 'deepl style-rules list' ) ;
765- expect ( true ) . toBe ( true ) ;
766767 } catch ( error : any ) {
767768 const output = error . stderr ?? error . stdout ;
768769 expect ( output ) . toMatch ( / A P I k e y | a u t h / i) ;
@@ -772,7 +773,6 @@ describe('CLI Workflow E2E', () => {
772773 it ( 'should accept --detailed and pagination flags' , ( ) => {
773774 try {
774775 runCLI ( 'deepl style-rules list --detailed --page 1 --page-size 10' ) ;
775- expect ( true ) . toBe ( true ) ;
776776 } catch ( error : any ) {
777777 const output = error . stderr ?? error . stdout ;
778778 expect ( output ) . not . toMatch ( / u n k n o w n .* o p t i o n / i) ;
@@ -784,7 +784,6 @@ describe('CLI Workflow E2E', () => {
784784 it ( 'should accept extended language codes like Swahili' , ( ) => {
785785 try {
786786 runCLI ( 'deepl translate "Hello" --to sw' ) ;
787- expect ( true ) . toBe ( true ) ;
788787 } catch ( error : any ) {
789788 const output = error . stderr ?? error . stdout ;
790789 expect ( output ) . not . toMatch ( / I n v a l i d t a r g e t l a n g u a g e / i) ;
@@ -794,7 +793,6 @@ describe('CLI Workflow E2E', () => {
794793 it ( 'should accept ES-419 Latin American Spanish' , ( ) => {
795794 try {
796795 runCLI ( 'deepl translate "Hello" --to es-419' ) ;
797- expect ( true ) . toBe ( true ) ;
798796 } catch ( error : any ) {
799797 const output = error . stderr ?? error . stdout ;
800798 expect ( output ) . not . toMatch ( / I n v a l i d t a r g e t l a n g u a g e / i) ;
@@ -804,7 +802,6 @@ describe('CLI Workflow E2E', () => {
804802 it ( 'should accept Chinese simplified/traditional variants' , ( ) => {
805803 try {
806804 runCLI ( 'deepl translate "Hello" --to zh-hant' ) ;
807- expect ( true ) . toBe ( true ) ;
808805 } catch ( error : any ) {
809806 const output = error . stderr ?? error . stdout ;
810807 expect ( output ) . not . toMatch ( / I n v a l i d t a r g e t l a n g u a g e / i) ;
@@ -818,7 +815,6 @@ describe('CLI Workflow E2E', () => {
818815 runCLI (
819816 'deepl translate "<p>Hello</p>" --to es --tag-handling html --tag-handling-version v2'
820817 ) ;
821- expect ( true ) . toBe ( true ) ;
822818 } catch ( error : any ) {
823819 const output = error . stderr ?? error . stdout ;
824820 expect ( output ) . not . toMatch ( / u n k n o w n .* o p t i o n / i) ;
0 commit comments