exercise2's Introduction
Shred Usage: `Shred("yourfilename")` Testing: Run `make run` or `bash create_test_files.sh` followed by `go test` Note: test files are created outside the go tests to allow the memory consumption of the go tests to be profile easier without being influenced by memory used during the creation of test cases Configuration: - ENABLE_LOGGING can be changed within shred.go Test cases handled: - handles cases where the file does not exist - throws an error when the file cannot be written to - handles both text and binary formats - handles files of varying sizes - deletes the file after shredding - ensures file contents before deletion is different to the original contents - records memory usage to check that it is capped (i.e. shredding 100MB file does not use 100MB of memory) - checking for open file handles after completion - empty files Test cases not handled: - behaviour with "non-standard" files, such as virtual filesystems, network drives, devices, etc. - low memory devices (although basic memory usage tracked) - simulating devices low on storage and handling "No space left on device" errors - checking file size is same before deleting - checking no subcontents of original file are found in contents before deleting
exercise2's People
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.