Offline in the browser
With IndexedDB, AppCache & LocalStorage
Internet Usage Rates
Asia
Europe
Africa
North America
Latin America
Australia
0

12.5

25

37.5

50
Asia

~ 28%

Europe

~ 64%

Africa

~ 16%

North America

~ 80%

Latin America

~ 43%

Australia

~ 68%

0

17.5

35

52.5...
I don’t have an internet issue. What’s in it for me?
I don’t have an internet issue. What’s in it for me?
I don’t have an internet issue. What’s in it for me?
Use case
“Simply put, it’s a way for web pages to store named key/value pairs
locally, within the client web browser.”
!

!
- divei...
Demo
Gotchas

•

“5 megabytes” is how much storage space each origin gets by
default.
Gotchas

•

“2.5 million characters” is how much storage space each origin
gets by default.
IndexedDB
“IndexedDB is an API for client-side storage of significant amounts of
structured data and for high performance ...
IndexedDB

LocalStorage
caniuse.com
Demo
ApplicationCache
“Developers can use the Application Cache (AppCache) interface to
specify resources that the browser shou...
AppCache is not
BrowserCache
Demo
Gotchas
•

Any changes made to the appcache file will cause the browser to
update the entire application cache."

•

If any...
Challenges
• How to automate indexedDB?"
• How to switch off network in between running
automation script?"

• Inform exact...
kansal.raman@gmail.com"
manan.bharara@gmail.com"

@kansal_raman"
@mananbharara

Thank You
www.nextgentesting.org
Offline browser testing
Offline browser testing
Offline browser testing
Offline browser testing
Offline browser testing
Offline browser testing
Upcoming SlideShare
Loading in …5
×

Offline browser testing

529 views

Published on

Published in: Technology
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
529
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
10
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Offline browser testing

  1. 1. Offline in the browser With IndexedDB, AppCache & LocalStorage
  2. 2. Internet Usage Rates Asia Europe Africa North America Latin America Australia 0 12.5 25 37.5 50
  3. 3. Asia ~ 28% Europe ~ 64% Africa ~ 16% North America ~ 80% Latin America ~ 43% Australia ~ 68% 0 17.5 35 52.5 70 % of population % of internet penetration
  4. 4. I don’t have an internet issue. What’s in it for me?
  5. 5. I don’t have an internet issue. What’s in it for me?
  6. 6. I don’t have an internet issue. What’s in it for me?
  7. 7. Use case
  8. 8. “Simply put, it’s a way for web pages to store named key/value pairs locally, within the client web browser.” ! ! - diveintohtml5.info _
  9. 9. Demo
  10. 10. Gotchas • “5 megabytes” is how much storage space each origin gets by default.
  11. 11. Gotchas • “2.5 million characters” is how much storage space each origin gets by default.
  12. 12. IndexedDB “IndexedDB is an API for client-side storage of significant amounts of structured data and for high performance searches on this data using indexes.” ! - developer.mozilla.org _
  13. 13. IndexedDB LocalStorage
  14. 14. caniuse.com
  15. 15. Demo
  16. 16. ApplicationCache “Developers can use the Application Cache (AppCache) interface to specify resources that the browser should cache and make available to offline users” ! - developer.mozilla.org _
  17. 17. AppCache is not BrowserCache
  18. 18. Demo
  19. 19. Gotchas • Any changes made to the appcache file will cause the browser to update the entire application cache." • If any of the files mentioned in the CACHE section can't be retrieved, the entire cache will be disregarded." • Regardless of whether you include the address of the current page in the configuration, it will be cached.
  20. 20. Challenges • How to automate indexedDB?" • How to switch off network in between running automation script?" • Inform exact point of failure" • CI integration" • Which browser to choose for automation testing?
  21. 21. kansal.raman@gmail.com" manan.bharara@gmail.com" @kansal_raman" @mananbharara Thank You www.nextgentesting.org

×