Content-Length: 268249 | pFad | http://github.com/go-python/gpython/commit/aab8fa41758eea280cada80485fd178311ba409f

D8 Add tests for slice · go-python/gpython@aab8fa4 · GitHub
Skip to content

Commit aab8fa4

Browse files
committed
Add tests for slice
1 parent ffcb977 commit aab8fa4

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

py/tests/slice.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Copyright 2019 The go-python Authors. All rights reserved.
2+
# Use of this source code is governed by a BSD-style
3+
# license that can be found in the LICENSE file.
4+
5+
doc="slice"
6+
a = slice(10)
7+
assert a.start == None
8+
assert a.stop == 10
9+
assert a.step == None
10+
11+
a = slice(0, 10, 1)
12+
assert a.start == 0
13+
assert a.stop == 10
14+
assert a.step == 1
15+
16+
doc="finished"

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/go-python/gpython/commit/aab8fa41758eea280cada80485fd178311ba409f

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy