|
@@ 88-97 (lines=10) @@
|
| 85 |
|
las.insert_curve(2, 'B', b1, descr='b1') |
| 86 |
|
assert [c.descr for c in las.curves] == ['', 'b2', 'b1'] |
| 87 |
|
|
| 88 |
|
def test_delete_curve_ix(): |
| 89 |
|
las = lasio.LASFile() |
| 90 |
|
a = np.array([1, 2, 3, 4]) |
| 91 |
|
b1 = np.array([5, 9, 1, 4]) |
| 92 |
|
b2 = np.array([1, 2, 3, 2]) |
| 93 |
|
las.append_curve('DEPT', a) |
| 94 |
|
las.append_curve('B', b2, descr='b2') |
| 95 |
|
las.insert_curve(2, 'B', b1, descr='b1') |
| 96 |
|
las.delete_curve(ix=0) |
| 97 |
|
assert [c.descr for c in las.curves] == ['b2', 'b1'] |
| 98 |
|
|
| 99 |
|
|
| 100 |
|
def test_delete_curve_mnemonic(): |
|
@@ 46-55 (lines=10) @@
|
| 43 |
|
# logger.debug(str(sl)) |
| 44 |
|
assert sl.keys() == ['DT', 'RHOB', 'NPHI'] |
| 45 |
|
|
| 46 |
|
def test_add_curve_duplicate(): |
| 47 |
|
las = lasio.LASFile() |
| 48 |
|
a = np.array([1, 2, 3, 4]) |
| 49 |
|
b1 = np.array([5, 9, 1, 4]) |
| 50 |
|
b2 = np.array([1, 2, 3, 2]) |
| 51 |
|
las.add_curve('DEPT', a) |
| 52 |
|
las.add_curve('B', b1, descr='b1') |
| 53 |
|
las.add_curve('B', b2, descr='b2') |
| 54 |
|
# assert l.keys == ['DEPT', 'B', 'B'] |
| 55 |
|
assert [c.descr for c in las.curves] == ['', 'b1', 'b2'] |
| 56 |
|
|
| 57 |
|
|
| 58 |
|
def test_append_curve_duplicate(): |
|
@@ 78-86 (lines=9) @@
|
| 75 |
|
las.insert_curve(1, 'B', b1, descr='b1') |
| 76 |
|
assert [c.descr for c in las.curves] == ['', 'b1', 'b2'] |
| 77 |
|
|
| 78 |
|
def test_insert_curve_2(): |
| 79 |
|
las = lasio.LASFile() |
| 80 |
|
a = np.array([1, 2, 3, 4]) |
| 81 |
|
b1 = np.array([5, 9, 1, 4]) |
| 82 |
|
b2 = np.array([1, 2, 3, 2]) |
| 83 |
|
las.append_curve('DEPT', a) |
| 84 |
|
las.append_curve('B', b2, descr='b2') |
| 85 |
|
las.insert_curve(2, 'B', b1, descr='b1') |
| 86 |
|
assert [c.descr for c in las.curves] == ['', 'b2', 'b1'] |
| 87 |
|
|
| 88 |
|
def test_delete_curve_ix(): |
| 89 |
|
las = lasio.LASFile() |
|
@@ 68-76 (lines=9) @@
|
| 65 |
|
las.append_curve('B', b2, descr='b2') |
| 66 |
|
assert [c.descr for c in las.curves] == ['', 'b1', 'b2'] |
| 67 |
|
|
| 68 |
|
def test_insert_curve_1(): |
| 69 |
|
las = lasio.LASFile() |
| 70 |
|
a = np.array([1, 2, 3, 4]) |
| 71 |
|
b1 = np.array([5, 9, 1, 4]) |
| 72 |
|
b2 = np.array([1, 2, 3, 2]) |
| 73 |
|
las.append_curve('DEPT', a) |
| 74 |
|
las.append_curve('B', b2, descr='b2') |
| 75 |
|
las.insert_curve(1, 'B', b1, descr='b1') |
| 76 |
|
assert [c.descr for c in las.curves] == ['', 'b1', 'b2'] |
| 77 |
|
|
| 78 |
|
def test_insert_curve_2(): |
| 79 |
|
las = lasio.LASFile() |
|
@@ 58-66 (lines=9) @@
|
| 55 |
|
assert [c.descr for c in las.curves] == ['', 'b1', 'b2'] |
| 56 |
|
|
| 57 |
|
|
| 58 |
|
def test_append_curve_duplicate(): |
| 59 |
|
las = lasio.LASFile() |
| 60 |
|
a = np.array([1, 2, 3, 4]) |
| 61 |
|
b1 = np.array([5, 9, 1, 4]) |
| 62 |
|
b2 = np.array([1, 2, 3, 2]) |
| 63 |
|
las.append_curve('DEPT', a) |
| 64 |
|
las.append_curve('B', b1, descr='b1') |
| 65 |
|
las.append_curve('B', b2, descr='b2') |
| 66 |
|
assert [c.descr for c in las.curves] == ['', 'b1', 'b2'] |
| 67 |
|
|
| 68 |
|
def test_insert_curve_1(): |
| 69 |
|
las = lasio.LASFile() |