<commit_before>module( "idb", {
    teardown: moduleTeardown
});

asyncTest( "Complete removal of object store", 1, function() {
    jar( "idb-1", "idb" )
        .done(function() {
            this.set( "1", "2" ).done(function() {
                this.get( "1" ).done(function( data ) {
                    this.remove()
                        .done(function() {
                            console.log( this.instances.idb.db.objectStoreNames )
                            ok( !~[].indexOf.call( this.instances.idb.db.objectStoreNames, "idb-1" ), "Store was completely removed" );
                        })
                        .fail(function() {
                            ok( false, "Store was not completely removed" );
                        })
                        .always( start );
                });
            });
        })
        .fail(function() {
            console.log(4)
        })
});

asyncTest( "Clear object store", 2, function() {
    var test = jar( "idb-2", "idb" ).done(function() {
        this.set( "1", "2" ).done(function() {
            this.get( "1" ).done(function( data ) {
                this.clear()
                    .done(function() {
                        ok( test.instances.idb.db.objectStoreNames.length === 1, "Store was cleared" );
                    })
                    .fail(function() {
                        ok( false, "Store was not cleared" );
                    })
                    .always( start );
            });
        });
    });
});

asyncTest( "Complete removal of object store", 1, function() {
    var test = jar( "idb-3", "idb" ).done(function() {
        this.set( "1", "2" ).done(function() {
            this.get( "1" ).done(function( data ) {
                this.remove().done(function() {
                    this.setup( "idb" )
                        .done(function() {
                            ok( test.instances.idb.db.objectStoreNames.length === 1, "Store was setted, after being removed" );
                            start();
                        })
                        .fail(function() {
                            ok( false, "Store was not setted, after being removed" );
                        })
                        .always( start );
                });
            });
        });
    });
});
<commit_msg>Remove console<commit_after>module( "idb", {
    teardown: moduleTeardown
});

asyncTest( "Complete removal of object store", 1, function() {
    jar( "idb-1", "idb" )
        .done(function() {
            this.set( "1", "2" ).done(function() {
                this.get( "1" ).done(function( data ) {
                    this.remove()
                        .done(function() {
                            ok( !~[].indexOf.call( this.instances.idb.db.objectStoreNames, "idb-1" ), "Store was completely removed" );
                        })
                        .fail(function() {
                            ok( false, "Store was not completely removed" );
                        })
                        .always( start );
                });
            });
        })
        .fail(function() {
            ok( false, "Can't create object store" );
        });
});

asyncTest( "Clear object store", 2, function() {
    var test = jar( "idb-2", "idb" ).done(function() {
        this.set( "1", "2" ).done(function() {
            this.get( "1" ).done(function( data ) {
                this.clear()
                    .done(function() {
                        ok( test.instances.idb.db.objectStoreNames.length === 1, "Store was cleared" );
                    })
                    .fail(function() {
                        ok( false, "Store was not cleared" );
                    })
                    .always( start );
            });
        });
    });
});

asyncTest( "Complete removal of object store", 1, function() {
    var test = jar( "idb-3", "idb" ).done(function() {
        this.set( "1", "2" ).done(function() {
            this.get( "1" ).done(function( data ) {
                this.remove().done(function() {
                    this.setup( "idb" )
                        .done(function() {
                            ok( test.instances.idb.db.objectStoreNames.length === 1, "Store was setted, after being removed" );
                            start();
                        })
                        .fail(function() {
                            ok( false, "Store was not setted, after being removed" );
                        })
                        .always( start );
                });
            });
        });
    });
});

{'fraction_non_alphanumeric': 0.1503367369107104, 'fraction_numerical': 0.008038235933087117, 'mean_word_length': 1.1167816091954024, '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': '1265204', 'n_tokens_mistral': 1252, 'n_tokens_neox': 1192, 'n_words': 270}