Skip to content

Instantly share code, notes, and snippets.

@dgorodnichy
Last active April 9, 2020 15:46
Show Gist options
  • Save dgorodnichy/373fd8a30d8fd58490782d71749c233e to your computer and use it in GitHub Desktop.
Save dgorodnichy/373fd8a30d8fd58490782d71749c233e to your computer and use it in GitHub Desktop.
posts_adapter_fake.rb
module PostsSource
class Fake
def initialize(username)
@client = OpenStruct.new(
posts: [
{
title: 'Signal v Noise exits Medium[Fake source]',
...
}
]
)
end
def user_posts
@client.posts
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment