( self )
| 202 | self.assertTrue( dd["ONE"].isSame( dd["TWO"] ) ) |
| 203 | |
| 204 | def testSaveInCurrentDir( self ) : |
| 205 | |
| 206 | o = IECore.CompoundData() |
| 207 | one = IECore.IntData( 1 ) |
| 208 | o["one"] = one |
| 209 | o["two"] = IECore.IntData( 2 ) |
| 210 | o["oneAgain"] = one |
| 211 | |
| 212 | fio = IECore.FileIndexedIO( os.path.join( "test", "o.fio" ), [], IECore.IndexedIO.OpenMode.Write ) |
| 213 | fio = fio.subdirectory( "a", IECore.IndexedIO.MissingBehaviour.CreateIfMissing ) |
| 214 | d = fio.path() |
| 215 | o.save( fio, "test" ) |
| 216 | self.assertEqual( fio.path(), d ) |
| 217 | del fio |
| 218 | |
| 219 | fio = IECore.FileIndexedIO( os.path.join( "test", "o.fio" ), ["a"], IECore.IndexedIO.OpenMode.Read ) |
| 220 | d = fio.path() |
| 221 | self.assertEqual( fio.path(), ["a"] ) |
| 222 | oo = o.load( fio, "test" ) |
| 223 | self.assertEqual( fio.path(), d ) |
| 224 | |
| 225 | self.assertEqual( o, oo ) |
| 226 | |
| 227 | def testSlashesInRepeatedData(self): |
| 228 | """Make sure slashes can be used and do not break the symlinks on the Object representation for repeated data.""" |
nothing calls this directly
no test coverage detected