Rails 6 API Tutorial - Fixing authentication specs and improving the codebase p.24

Опубликовано: 04 Ноябрь 2024
на канале: Rails Pro
2,078
76

In this video series we will build a Rails API from scratch. Backend APIs are useful for serving data to frontend applications, mobile apps or other backend services.

✨ Check out the new version of this video series, which has been updated for Rails 7    • Rails 7 API Tutorial - Create project...  

📖 You can also purchase the eBook and code for the new Rails 7 tutorial - https://tomkadwill.gumroad.com/l/rail...

This video covers:
00:18 - Running specs to check for failing tests
00:36 - Fixing controller specs by stubbing AuthenticationTokenService
05:31 - Fixing request specs by including a JWT Authorization header with a valid user id
10:52 - Fixing controller to return a 401 when Authorization header is missing, instead of raising an exception
18:31 - Updating AuthenticationTokenService method names

If you’re new to this series, you may want to start with part 1:    • Rails 6 API Tutorial - Create project...