1# This file is part of h5py, a Python interface to the HDF5 library. 2# 3# http://www.h5py.org 4# 5# Copyright 2008-2013 Andrew Collette and contributors 6# 7# License: Standard 3-clause BSD; see "license.txt" for full license terms 8# and contributor agreement. 9 10""" 11 Tests the h5py.Dataset.dims.DimensionProxy class. 12""" 13 14import numpy as np 15import h5py 16 17from .common import ut, TestCase 18 19class TestItems(TestCase): 20 21 def test_empty(self): 22 """ no dimension scales -> empty list """ 23 dset = self.f.create_dataset('x', (10,)) 24 self.assertEqual(dset.dims[0].items(), []) 25