Skip to content

Commit 6fc099a

Browse files
committed
Implement stat module
1 parent f0c7cb2 commit 6fc099a

File tree

3 files changed

+571
-12
lines changed

3 files changed

+571
-12
lines changed

Lib/test/test_stat.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -239,13 +239,9 @@ def test_file_attribute_constants(self):
239239
class TestFilemodeCStat(TestFilemode, unittest.TestCase):
240240
statmod = c_stat
241241

242-
# TODO: RUSTPYTHON
243-
@unittest.expectedFailure
244242
def test_devices(self):
245243
super().test_devices()
246244

247-
# TODO: RUSTPYTHON
248-
@unittest.expectedFailure
249245
def test_directory(self):
250246
super().test_directory()
251247

@@ -254,23 +250,15 @@ def test_directory(self):
254250
def test_file_attribute_constants(self):
255251
super().test_file_attribute_constants()
256252

257-
# TODO: RUSTPYTHON
258-
@unittest.expectedFailure
259253
def test_link(self):
260254
super().test_link()
261255

262-
# TODO: RUSTPYTHON
263-
@unittest.expectedFailure
264256
def test_mode(self):
265257
super().test_mode()
266258

267-
# TODO: RUSTPYTHON
268-
@unittest.expectedFailure
269259
def test_module_attributes(self):
270260
super().test_module_attributes()
271261

272-
# TODO: RUSTPYTHON
273-
@unittest.expectedFailure
274262
def test_socket(self):
275263
super().test_socket()
276264

vm/src/stdlib/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ mod operator;
1414
// TODO: maybe make this an extension module, if we ever get those
1515
// mod re;
1616
mod sre;
17+
mod stat;
1718
mod string;
1819
#[cfg(feature = "compiler")]
1920
mod symtable;
@@ -89,6 +90,7 @@ pub fn get_module_inits() -> StdlibMap {
8990
"_operator" => operator::make_module,
9091
"_signal" => signal::make_module,
9192
"_sre" => sre::make_module,
93+
"_stat" => stat::make_module,
9294
"_string" => string::make_module,
9395
"time" => time::make_module,
9496
"_typing" => typing::make_module,

0 commit comments

Comments
 (0)