mirror of
https://github.com/wassname/geopandas.git
synced 2026-09-12 12:20:25 +08:00
Test equals operator
This commit is contained in:
@@ -30,6 +30,10 @@ class TestSeries(unittest.TestCase):
|
||||
l = np.array([2 + np.sqrt(2), 4])
|
||||
assert np.allclose(self.g1.length.values, l)
|
||||
|
||||
def test_equals(self):
|
||||
assert np.alltrue(self.g1.equals(self.g1))
|
||||
assert np.all(self.g1.equals(self.sq).values == np.array([0, 1], dtype=bool))
|
||||
|
||||
def test_union_series(self):
|
||||
u = self.g1.union(self.g2)
|
||||
assert u[0].equals(self.sq)
|
||||
|
||||
Reference in New Issue
Block a user