@@ -12,25 +12,31 @@ describe('Get Quota', function () {
1212 expect ( prefs ) . to . be . a ( 'string' )
1313 expect ( prefs ) . to . match ( / s t o r a g e Q u o t a / )
1414 } )
15- it ( 'Get the quota' , function ( done ) {
16- expect ( getQuota ( path . join ( 'test/resources/' , root ) , 'https://localhost' ) ) . to . eventually . equal ( 2000 )
15+ it ( 'Get the quota' , async function ( ) {
16+ const quota = await getQuota ( path . join ( 'test/resources/' , root ) , 'https://localhost' )
17+ expect ( quota ) . to . equal ( 2000 )
1718 } )
18- /* it('Get the quota with non-existant file', function () {
19- expect(getQuota(path.join('nowhere/', root), 'https://localhost')).to.equal(Infinity)
19+ it ( 'Get the quota with non-existant file' , async function ( ) {
20+ const quota = await getQuota ( path . join ( 'nowhere/' , root ) , 'https://localhost' )
21+ expect ( quota ) . to . equal ( Infinity )
22+ } )
23+ it ( 'Get the quota when the predicate is not present' , async function ( ) {
24+ const quota = await getQuota ( 'test/resources/accounts-acl/quota' , 'https://localhost' )
25+ expect ( quota ) . to . equal ( Infinity )
2026 } )
21- it('Get the quota when the predicate is not present', function () {
22- expect(getQuota('test/resources/accounts-acl/quota', 'https://localhost')).to.equal(Infinity)
23- }) */
2427} )
2528
2629describe ( 'Check if over Quota' , function ( ) {
27- it ( 'Check the quota' , function ( ) {
28- expect ( overQuota ( path . join ( 'test/resources/' , root ) , 'https://localhost' ) ) . to . be . true
30+ it ( 'Check the quota' , async function ( ) {
31+ const quota = await overQuota ( path . join ( 'test/resources/' , root ) , 'https://localhost' )
32+ expect ( quota ) . to . be . true
2933 } )
30- it ( 'Check the quota with non-existant file' , function ( ) {
31- expect ( overQuota ( path . join ( 'nowhere/' , root ) , 'https://localhost' ) ) . to . be . false
34+ it ( 'Check the quota with non-existant file' , async function ( ) {
35+ const quota = await overQuota ( path . join ( 'nowhere/' , root ) , 'https://localhost' )
36+ expect ( quota ) . to . be . false
3237 } )
33- it ( 'Check the quota when the predicate is not present' , function ( ) {
34- expect ( overQuota ( 'test/resources/accounts-acl/quota' , 'https://localhost' ) ) . to . be . false ( )
38+ it ( 'Check the quota when the predicate is not present' , async function ( ) {
39+ const quota = await overQuota ( 'test/resources/accounts-acl/quota' , 'https://localhost' )
40+ expect ( quota ) . to . be . false
3541 } )
3642} )
0 commit comments