New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃梽馃敡 Haskell / Yesod #202

Closed
tzemanovic opened this Issue Apr 15, 2018 · 5 comments

Comments

Projects
None yet
3 participants
@tzemanovic
Contributor

tzemanovic commented Apr 15, 2018

Current Status

Codebase in progress: https://github.com/tzemanovic/haskell-yesod-realworld-example-app

Todo:

  • 馃弫 Fork the starter repo & post the link in this issue
  • 馃帹 Create logo for repo & update issue status (@EricSimons)
  • 馃敤 Implement all of Conduit's functionality per the spec & API
  • 馃憖 Move repo to main org & Peer review final codebase by admins/community (RFC)
  • 馃帀 Tag v1 release and officially list it on the README!

@tzemanovic tzemanovic changed the title from Haskell / Yesod to 馃梽馃敡 Haskell / Yesod Jul 11, 2018

@tzemanovic

This comment has been minimized.

Contributor

tzemanovic commented Aug 19, 2018

Hi, I've got this implementation ready. Please, let me know what to do for the next step.

@anishkny

This comment has been minimized.

Member

anishkny commented Aug 19, 2018

@tzemanovic this looks amazing! 馃檶 a few suggestions:

  1. Could you summarize "How it works" in the README itself (its okay if not the whole blog post, at least some key information)?
  2. Could you run Postman API tests against your stack to ensure they work, and maybe even add to Travis YML file?

Great work!!!

@anishkny anishkny added rfc and removed wip labels Aug 19, 2018

@tzemanovic

This comment has been minimized.

Contributor

tzemanovic commented Aug 25, 2018

Hi Anish, thank you!

  1. I've had a link to a blog post with overview of the project, but it wasn't very visible, so I've updated it.
  2. Thanks for fixing the tests in #255, I've ran them and all are passing except for the timestamp tests such as:

tests['Article\\'s \"createdAt\" property is an ISO 8601 timestamp'] = new Date(article.createdAt).toISOString() === article.createdAt;",

SQLite seems to be using 3 more decimals for microseconds, which get lost in the new Date(t).toISOString() conversion, but this is a valid ISO 8601 date.

@tzemanovic

This comment has been minimized.

Contributor

tzemanovic commented Aug 30, 2018

With the updates from #255 and #260, this is passing the postman tests now:

Conduit

鉂 Auth
鈫 Register
  POST https://localhost:3443/api/users [200 OK, 733B, 79ms]
  鉁  Response contains "user" property
  鉁  User has "email" property
  鉁  User has "username" property
  鉁  User has "bio" property
  鉁  User has "image" property
  鉁  User has "token" property

鈫 Login
  POST https://localhost:3443/api/users/login [200 OK, 733B, 33ms]
  鉁  Response contains "user" property
  鉁  User has "email" property
  鉁  User has "username" property
  鉁  User has "bio" property
  鉁  User has "image" property
  鉁  User has "token" property

鈫 Login and Remember Token
  POST https://localhost:3443/api/users/login [200 OK, 733B, 31ms]
  鉁  Response contains "user" property
  鉁  User has "email" property
  鉁  User has "username" property
  鉁  User has "bio" property
  鉁  User has "image" property
  鉁  User has "token" property
  鉁  Global variable "token" has been set

鈫 Current User
  GET https://localhost:3443/api/user [200 OK, 733B, 4ms]
  鉁  Response contains "user" property
  鉁  User has "email" property
  鉁  User has "username" property
  鉁  User has "bio" property
  鉁  User has "image" property
  鉁  User has "token" property

鈫 Update User
  PUT https://localhost:3443/api/user [200 OK, 732B, 6ms]
  鉁  Response contains "user" property
  鉁  User has "email" property
  鉁  User has "username" property
  鉁  User has "bio" property
  鉁  User has "image" property
  鉁  User has "token" property

鉂 Articles
鈫 All Articles
  GET https://localhost:3443/api/articles [200 OK, 436B, 4ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鈫 Articles by Author
  GET https://localhost:3443/api/articles?author=johnjacob [200 OK, 436B, 4ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鈫 Articles Favorited by Username
  GET https://localhost:3443/api/articles?favorited=jane [200 OK, 436B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鈫 Articles by Tag
  GET https://localhost:3443/api/articles?tag=dragons [200 OK, 436B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鉂 Articles, Favorite, Comments
鈫 Create Article
  POST https://localhost:3443/api/articles [200 OK, 834B, 11ms]
  鉁  Response contains "article" property
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Feed
  GET https://localhost:3443/api/articles/feed [200 OK, 436B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鈫 All Articles
  GET https://localhost:3443/api/articles [200 OK, 855B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 All Articles with auth
  GET https://localhost:3443/api/articles [200 OK, 855B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Articles by Author
  GET https://localhost:3443/api/articles?author=tzemanovic [200 OK, 855B, 5ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Articles by Author with auth
  GET https://localhost:3443/api/articles?author=tzemanovic [200 OK, 855B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Articles Favorited by Username
  GET https://localhost:3443/api/articles?favorited=jane [200 OK, 436B, 2ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鈫 Articles Favorited by Username with auth
  GET https://localhost:3443/api/articles?favorited=jane [200 OK, 436B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  articlesCount is 0 when feed is empty

鈫 Single Article by slug
  GET https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b [200 OK, 834B, 3ms]
  鉁  Response contains "article" property
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Articles by Tag
  GET https://localhost:3443/api/articles?tag=dragons [200 OK, 855B, 4ms]
  鉁  Response code is 200 OK
  鉁  Response contains "articles" property
  鉁  Response contains "articlesCount" property
  鉁  articlesCount is an integer
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Update Article
  PUT https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b [200 OK, 833B, 4ms]
  鉁  Response contains "article" property
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer

鈫 Favorite Article
  POST https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b/favorite [200 OK, 832B, 4ms]
  鉁  Response contains "article" property
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article's 'favorited' property is true
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer
  鉁  Article's 'favoritesCount' property is greater than 0

鈫 Unfavorite Article
  DELETE https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b/favorite [200 OK, 833B, 3ms]
  鉁  Response contains "article" property
  鉁  Article has "title" property
  鉁  Article has "slug" property
  鉁  Article has "body" property
  鉁  Article has "createdAt" property
  鉁  Article's "createdAt" property is an ISO 8601 timestamp
  鉁  Article has "updatedAt" property
  鉁  Article's "updatedAt" property is an ISO 8601 timestamp
  鉁  Article has "description" property
  鉁  Article has "tagList" property
  鉁  Article's "tagList" property is an Array
  鉁  Article has "author" property
  鉁  Article has "favorited" property
  鉁  Article has "favoritesCount" property
  鉁  favoritesCount is an integer
  鉁  Article's "favorited" property is true

鈫 Create Comment for Article
  POST https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b/comments [200 OK, 665B, 4ms]
  鉁  Response contains "comment" property
  鉁  Comment has "id" property
  鉁  Comment has "body" property
  鉁  Comment has "createdAt" property
  鉁  "createdAt" property is an ISO 8601 timestamp
  鉁  Comment has "updatedAt" property
  鉁  "updatedAt" property is an ISO 8601 timestamp
  鉁  Comment has "author" property

鈫 All Comments for Article
  GET https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b/comments [200 OK, 668B, 2ms]
  鉁  Response code is 200 OK
  鉁  Response contains "comments" property
  鉁  Comment has "id" property
  鉁  Comment has "body" property
  鉁  Comment has "createdAt" property
  鉁  "createdAt" property is an ISO 8601 timestamp
  鉁  Comment has "updatedAt" property
  鉁  "updatedAt" property is an ISO 8601 timestamp
  鉁  Comment has "author" property

鈫 Delete Comment for Article
  DELETE https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b/comments/1 [200 OK, 407B, 2ms]

鈫 Delete Article
  DELETE https://localhost:3443/api/articles/how-to-train-your-dragon-toll6b [200 OK, 407B, 3ms]

鉂 Profiles
鈫 Register Celeb
  POST https://localhost:3443/api/users [200 OK, 745B, 31ms]
  鉁  Response contains "user" property
  鉁  User has "email" property
  鉁  User has "username" property
  鉁  User has "bio" property
  鉁  User has "image" property
  鉁  User has "token" property

鈫 Profile
  GET https://localhost:3443/api/profiles/celeb_tzemanovic [200 OK, 541B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "profile" property
  鉁  Profile has "username" property
  鉁  Profile has "bio" property
  鉁  Profile has "image" property
  鉁  Profile has "following" property

鈫 Follow Profile
  POST https://localhost:3443/api/profiles/celeb_tzemanovic/follow [200 OK, 540B, 4ms]
  鉁  Response code is 200 OK
  鉁  Response contains "profile" property
  鉁  Profile has "username" property
  鉁  Profile has "bio" property
  鉁  Profile has "image" property
  鉁  Profile has "following" property
  鉁  Profile's "following" property is true

鈫 Unfollow Profile
  DELETE https://localhost:3443/api/profiles/celeb_tzemanovic/follow [200 OK, 541B, 3ms]
  鉁  Response code is 200 OK
  鉁  Response contains "profile" property
  鉁  Profile has "username" property
  鉁  Profile has "bio" property
  鉁  Profile has "image" property
  鉁  Profile has "following" property
  鉁  Profile's "following" property is false

鉂 Tags
鈫 All Tags
  GET https://localhost:3443/api/tags [200 OK, 434B, 2ms]
  鉁  Response code is 200 OK
  鉁  Response contains "tags" property
  鉁  "tags" property returned as array

鈹屸攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹                         鈹 executed 鈹   failed 鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹              iterations 鈹        1 鈹        0 鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹                requests 鈹       31 鈹        0 鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹            test-scripts 鈹       46 鈹        0 鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹      prerequest-scripts 鈹       17 鈹        0 鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹尖攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹              assertions 鈹      280 鈹        0 鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹粹攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹粹攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹 total run duration: 1024ms                    鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹 total data received: 7.43KB (approx)          鈹
鈹溾攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
鈹 average response time: 8ms                    鈹
鈹斺攢鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹鈹
@anishkny

This comment has been minimized.

Member

anishkny commented Aug 31, 2018

Fantastic!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment