๐Ÿ—ป James Van Dyne

โœˆ๏ธTrips ๐Ÿ—บ๏ธMaps โœ๏ธ๏ธBlog ๐Ÿ”—๏ธ๏ธLinks ๐Ÿ‘‰Now ๐ŸƒRuns
  • ๐ŸกHome
  • โœˆ๏ธTrips
  • ๐Ÿ—บ๏ธMaps
  • โœ๏ธBlog
  • ๐Ÿ”—๏ธLinks
  • ๐Ÿ‘‰Now
  • ๐ŸƒRuns
  • โœ๏ธArticles
  • ๐Ÿ“ค๏ธReplies
  • ๐Ÿ’ฌStatus
  • ๐Ÿ”–๏ธ๏ธBookmarks
  • ๐Ÿ—บCheckins
  • ๐Ÿ“…The Week
  • ๐Ÿ–ฅTech
  • ๐ŸŒฒSustainability
  • ๐ŸƒRunning
  • ๐Ÿง Thoughts
  • ๐Ÿ‡ฏ๐Ÿ‡ตJapan
  • ๐Ÿ’กTIL
  • โ›ฐTanzawa
  • ๐ŸกHome
  • โœ๏ธArticles
  • ๐Ÿ“ค๏ธReplies
  • ๐Ÿ’ฌStatus
  • ๐Ÿ”–๏ธ๏ธBookmarks
  • ๐Ÿ—บCheckins
  • ๐Ÿ“…The Week
  • ๐Ÿ–ฅTech
  • ๐ŸŒฒSustainability
  • ๐ŸƒRunning
  • ๐Ÿง Thoughts
  • ๐Ÿ‡ฏ๐Ÿ‡ตJapan
  • ๐Ÿ’กTIL
  • โ›ฐTanzawa
  • Checkin to LaGuardia Airport (LGA)

    LaGuardia Airport (LGA) 40.77288813003166 -73.86880874633789
    Aug 15, 2016
    by James
    in East Elmhurst, NY, United States
    Seeing the NY sky-line and diving down to the runway is a lot of fun.
    ๐Ÿ”—permalink
  • Aug 15, 2016
    by James
    Catching a bird to New York.
    Not my bird.
    ๐Ÿ”—permalink
  • Checkin to Barbazzar

    Barbazzar 29.54443848657045 -95.13530604422768
    Aug 14, 2016
    by James
    in Webster, TX, United States
    ๐Ÿ”—permalink
  • Checkin to Bay Glen Animal Hospital

    Bay Glen Animal Hospital 29.584891 -95.146598
    Aug 12, 2016
    by James
    in Houston, TX, United States
    ๐Ÿ”—permalink
  • Quality isn't an accident

    Aug 12, 2016
    by James
    How many times have you tried to plug in a USB cable and failed on the first try? If youโ€™re like me that number is nearly the number of times Iโ€™ve ever attempted to connect a USB device. How many times has this happened with a network cable?

    While most people have heard of the term kaizen, or continuous improvement, when talking about Toyota and itโ€™s lean manufacturing principles, fewer have heard of kaizenโ€™s unsung sibling poka-yoke, or mistake proofing.ย 

    The main idea of poka-yoke is to draw attention to human errors as they occur, so they can be corrected or prevented, reducing the number of defects in a product. After observing a defect, we identify the root cause of the mistake, and then apply a fix or change in process that attempts to prevent the same error from happening again. This learning can then be applied to improve the design and function products.

    Building your products with poka-yoke requires more initial effort, however the end result is a higher quality and more reliable product. As developers, our tool to poka-yoke our services are unit tests.

    Tests are small pieces of software that exercise a piece of code and verify that itโ€™s behaving as intended. Writing tests are, however, many developers least favorite thing about creating software. We like to build new services and libraries because theyโ€™re fun and there is a sense of immediate gratification.

    While writing good tests is time consuming and not fun. Setting up the scaffolding, defining test cases, and setting the test data can feel like tedious grunt work without an end in sight. However boring tests may be, they are essential to quality software.

    With Kwoosh weโ€™re aiming for high reliability, minimum regressions, and fast operations. Part of our testing strategy is to have โ€œworkflowโ€ integration tests. These tests aim to help make certain that our tests are comprehensive while being easy to understand.

    Each test currently has a maximum of two tests named โ€˜test_get_workflowโ€™ and โ€˜test_post_workflowโ€™. Each test then calls a series of descriptively named helper functions to assert behavior.

    def test_get_workflow(self):
        # Make sure that anonymous users are redirected to login
        # and that users are denied access to data that's not theirs
        self.redirect_for_anon_get()
        self.not_found_for_wrong_account() 
        # Check that our filter interface is filtering data properly so
        # calls to "mine" only show tasks assigned to me and so forth.
        self.filters_response(self.sub_task_data['title'], 'all', [])
        self.filters_response(self.my_task_data['title'], 'mine',
            [self.sub_task_data['title'],
            self.completed_task_data['title']]
        )
        self.filters_response(self.completed_task_data['title'],
            'complete',
            [self.sub_task_data['title'],
            self.my_task_data['title']]
        )
    
    def test_post_workflow(self):
        # Make sure that all post requests are redirect
        # or return 405 and denied
        self.redirect_for_anon_post()
        self.post_not_allowed()

    As a lot of the tests will have some helpers in common (such as confirming anonymous users get redirected to login), we can bundle up these helper methods in small classes and include them into the tests, reducing the amount of code we need to maintain.


    ย Less code = Fewer places for bugs = Less maintenance

    Having descriptively named helper methods will allow future me to glance at the test I wrote today and identify exactly whatโ€™s being tested, without having to read through hundreds of lines of code.

    Quality isnโ€™t many things. Quality isnโ€™t free. It isnโ€™t flashy. It isnโ€™t fancy. And it sure as hell isnโ€™t an accident.
    ๐Ÿ”—permalink
  • Checkin to Starbucks

    Starbucks 29.548006 -95.09785
    Aug 11, 2016
    by James
    in Houston, TX, United States
    ๐Ÿ”—permalink
  • Checkin to Snap Fitness

    Snap Fitness 29.56033115395914 -95.03859121046696
    Aug 11, 2016
    by James
    in Seabrook, TX, United States
    ๐Ÿ”—permalink
  • Checkin to El Ranchero Mexican Restaurant

    El Ranchero Mexican Restaurant 29.66552937026435 -95.02179164890856
    Aug 08, 2016
    by James
    in La Porte, TX, United States
    ๐Ÿ”—permalink
  • Checkin to Lu's Barber Shop - Haircut & Shave

    Lu's Barber Shop - Haircut & Shave 29.5724885644525 -95.11025421981812
    Aug 08, 2016
    by James
    in Houston, TX, United States
    ๐Ÿ”—permalink
  • Checkin to Pho Hoang

    Pho Hoang 29.57302692217345 -95.108512495811
    Aug 08, 2016
    by James
    in Houston, TX, United States
    ๐Ÿ”—permalink
Previous 308 of 359 Next
Reply by email
Powered by
๐Ÿ”Tanzawa

โ† An IndieWeb Webring ๐Ÿ•ธ๐Ÿ’โ†’
Photo of James Van Dyne James Van Dyne Japan

Web developer living in Japan.