<commit_before>'use strict';

var sandboxFactory = require('..'),
    MemoryFS = require('memory-fs'),
    memoryFS = new MemoryFS(),
    sandbox = sandboxFactory.create(memoryFS);

memoryFS.mkdirpSync('/my/dir');
memoryFS.writeFileSync(
    '/my/dir/file1.js',
    'console.log("File1"); require("./file2.js"); console.log("Then"); require("/my/dir"); console.log("End");'
);
memoryFS.writeFileSync(
    '/my/dir/index.js',
    'console.log("Index");'
);
memoryFS.writeFileSync(
    '/my/dir/file2.js',
    'console.log("File2");'<commit_msg>Switch demo to use mock-fs rather than memory-fs<commit_after>'use strict';

var sandboxFactory = require('..'),
    mockFS = require('mock-fs').fs(),
    sandbox = sandboxFactory.create(mockFS);

mockFS.mkdirSync('/my');
mockFS.mkdirSync('/my/dir');
mockFS.writeFileSync(
    '/my/dir/file1.js',
    'console.log("File1"); require("./file2.js"); console.log("Then"); require("/my/dir"); console.log("End");'
);
mockFS.writeFileSync(
    '/my/dir/index.js',
    'console.log("Index");'
);
mockFS.writeFileSync(
    '/my/dir/file2.js',
    'console.log("File2");'
{'fraction_non_alphanumeric': 0.2244343891402715, 'fraction_numerical': 0.00904977375565611, 'mean_word_length': 4.3173076923076925, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2170394', 'n_tokens_mistral': 396, 'n_tokens_neox': 392, 'n_words': 56}