1- import { assert , assertEquals , assertNotEquals , assertObjectMatch } from '@std/assert'
1+ import { assert , assertEquals , assertNotStrictEquals , assertObjectMatch , assertStrictEquals } from '@std/assert'
22import { pathToFile } from './filetree.ts'
33import { loadTSV } from './tsv.ts'
44import { streamFromString } from '../tests/utils.ts'
@@ -119,8 +119,7 @@ Deno.test('TSV loading', async (t) => {
119119 // Replace stream to ensure cache does not depend on deep object equality
120120 file . stream = streamFromString ( text )
121121 let repeatMap = await loadTSV ( file , 2 )
122- // Equality is identity for objects
123- assertEquals ( map , repeatMap )
122+ assertStrictEquals ( map , repeatMap )
124123
125124 loadTSV . cache . clear ( )
126125 // DO NOT replace stream so the next read verifies the previous stream wasn't read
@@ -129,7 +128,7 @@ Deno.test('TSV loading', async (t) => {
129128 assertEquals ( repeatMap . b , [ '2' , '2' ] )
130129 assertEquals ( repeatMap . c , [ '3' , '3' ] )
131130 // Same contents, different objects
132- assertNotEquals ( map , repeatMap )
131+ assertNotStrictEquals ( map , repeatMap )
133132 } )
134133
135134 await t . step ( 'caching is keyed on maxRows' , async ( ) => {
@@ -145,14 +144,14 @@ Deno.test('TSV loading', async (t) => {
145144
146145 file . stream = streamFromString ( text )
147146 let repeatMap = await loadTSV ( file , 3 )
148- assertNotEquals ( map , repeatMap )
147+ assertNotStrictEquals ( map , repeatMap )
149148 assertEquals ( repeatMap . a , [ '1' , '1' , '1' ] )
150149 assertEquals ( repeatMap . b , [ '2' , '2' , '2' ] )
151150 assertEquals ( repeatMap . c , [ '3' , '3' , '3' ] )
152151
153152 file . stream = streamFromString ( text )
154153 repeatMap = await loadTSV ( file , 2 )
155- assertEquals ( map , repeatMap )
154+ assertStrictEquals ( map , repeatMap )
156155 assertEquals ( repeatMap . a , [ '1' , '1' ] )
157156 assertEquals ( repeatMap . b , [ '2' , '2' ] )
158157 assertEquals ( repeatMap . c , [ '3' , '3' ] )
0 commit comments