wspurgin / rspec-sidekiq Goto Github PK
View Code? Open in Web Editor NEWRSpec for Sidekiq
Home Page: https://github.com/wspurgin/rspec-sidekiq
License: Other
RSpec for Sidekiq
Home Page: https://github.com/wspurgin/rspec-sidekiq
License: Other
Version 2.1 seems ready to roll, but it's not on rubygems yet. Perhaps time to make a release?
When I use this gem in a Rails project by including rspec-sidekiq
in my Gemfile:
group :test do
gem 'fuubar'
end
I get a warning "irb: warn: can't alias context from irb_context." when I run bundle exec rails c
There's an old dependency somewhere that's causing bundler to require Ruby 1.9.2. I haven't spent too much time looking into why, but I wanted to get an issue logged before it slipped my mind.
[:~/Source/rspec-sidekiq] master ± bundle install
Fetching gem metadata from https://rubygems.org/.........
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Installing timers (1.1.0)
Installing celluloid (0.14.0)
Gem::InstallError: celluloid requires Ruby version >= 1.9.2.
An error occurred while installing celluloid (0.14.0), and Bundler cannot continue.
Make sure that `gem install celluloid -v '0.14.0'` succeeds before bundling.
Currently in the "red" zone. Improve for 1.0.0 release
Add code coverage indicator from Coveralls.io
Hello,
first of all, thanks for this awesome gem :)
I'm currently using rspec-sidekiq, now I'd like to add a separate test with a real sidekiq connection so I'd like to disable this gem in an integration test (cucumber or rspec):
describe MyWorker do
before do
# disable rspec-sidekiq here
end
it "really processes my worker" do
10.times |i|
MyWorker.perform_async i
end
end
end
What is the right way to do achieve this?
Probably I should also put in a Procfile.test the following content and have it run before executing my integration test, what do you think?
worker: bundle exec sidekiq -c 15
Regards,
Adit Saxena
Hey,
When I run the rspec-sidekiq
specs locally using bundle exec rspec spec
I get 4 failures:
rspec ./spec/rspec/sidekiq/matchers/have_enqueued_job_spec.rb:29 # RSpec::Sidekiq::Matchers::HaveEnqueuedJob expected usage matches on an enqueued ActiveJob
rspec ./spec/rspec/sidekiq/matchers/have_enqueued_job_spec.rb:33 # RSpec::Sidekiq::Matchers::HaveEnqueuedJob expected usage matches on an enqueued ActiveJob by global_id
rspec ./spec/rspec/sidekiq/matchers/have_enqueued_job_spec.rb:37 # RSpec::Sidekiq::Matchers::HaveEnqueuedJob expected usage matches on ActionMailer Job
rspec ./spec/rspec/sidekiq/matchers/have_enqueued_job_spec.rb:45 # RSpec::Sidekiq::Matchers::HaveEnqueuedJob expected usage matches on ActionMailer with a resource Job
All dependencies are installed. I tested this against both ruby 2.1.5
and the latest 2.2.4
and also both the develop
branch and the master
branch. Anything more than bundle exec rspec spec
I need to run or be aware of?
In the Batches feature of Sidekiq Pro we can declare a callback to be called when the batch completes/succeeds.
rspec-sidekiq has made it much easier for us to test the batch functionality (which I appreciate!), but I don't see a way to test this callback functionality. I'm guessing it's because of the NullObject implementation of Batch, but I'm not sure.
Is there a way to test the callback functionality within rspec-sidekiq? Or, if not, any suggestions on how I might start tackling this PR?
An error currently exists to stop people using this matcher.... Time for it to be completely removed
In previous versions (2.0.0), if you had a worker that accepted a hash parameter, you could do the following test:
expect(Sidekiq::Worker).to have_enqueued_job 123, true, 'param1' => 'abc456'
After update to 2.1.0 it fails with: TypeError: no implicit conversion of String into Integer
at: lib/rspec/matchers/have_enqueued_job.rb:56
While working on my gem: http://sidekiq-orm.github.io
I wanted to be able to test Sidekiq::ActiveRecord::ManagerWorker
, which uses Sidekiq::Client.push_bulk
, e.g
def batch_args(*ids)
{class: custom_worker_class, args: ids.map{ |id| [id] }}
end
context 'as method arguments' do
it 'pushes a bulk of all user ids for the specified worker_class' do
expect(sidekiq_client).to receive(:push_bulk).with( batch_args(user_1.id, user_2.id, user_3.id) )
run_worker({:worker_class => custom_worker_class})
end
end
It would be great if I could do:
expect(custom_worker_class).to have_enqueued_jobs_in_bulk([ [id1], [id2] ])
for more info on Sidekiq::ActiveRecord::ManagerWorker
:
https://github.com/sidekiq-orm/sidekiq-activerecord/wiki/Manager-Worker
https://github.com/sidekiq-orm/sidekiq-activerecord/blob/master/lib/sidekiq/active_record/manager_worker.rb
@philostler WDYT?
We have gem 'rspec-rails', '~> 3.0.0.beta'
in the Gemfile
.
On adding gem 'rspec-sidekiq'
, we get:
Bundler could not find compatible versions for gem "rspec-core":
In Gemfile:
rspec-sidekiq (>= 0) ruby depends on
rspec-core (= 2.0.0) ruby
rspec-rails (~> 3.0.0.beta) ruby depends on
rspec-core (3.0.0.beta1)
Since rspec 3 is going to be in beta for sometime, it'd be good to fix it to work with pre released version(s).
Using RSpec 3, I get the following message when using be_delayed
:
Deprecation Warnings:
--------------------------------------------------------------------------------
RSpec::Sidekiq::Matchers::BeDelayed implements a legacy RSpec matcher
protocol. For the current protocol you should expose the failure messages
via the `failure_message` and `failure_message_when_negated` methods.
Hi!
I can't seem to figure out how the be_delayed matcher from master is supposed to be used with ActionMailer classes. Since ActionMailer does some funky stuff with instance and class methods I can't use the matchers as documented.
expect(MyMailer.method :notification).to be_delayed('Hello')
fails with a NameError: undefined method.
I can work around that with a fake Method
object like this:
expect(OpenStruct.new(receiver: MyMailer, name: :notification)).to be_delayed('Hello')
but that doesn't feel right at all.
Any hints on how the matcher is supposed to be used in this case are greatly appreciated.
A quick read of Sidekiq's code base appears to show that arguments of jobs are serialized to JSON for injection into Redis and are thus converted to strings automatically.
This means that the following statements are equal...
sidekiq_options queue: :download
sidekiq_options queue: "download"
...representing the same intent and the same end result.
However the the following written matchers are not equal...
it { should be_processed_in :download }
it { should be_processed_in "download" }
Should the matcher convert all expected values to strings by default so that an queue defined as :download
passes when the matcher input is "download"
?
Remove restriction on having to use sidekiq-middleware with the be_unique matcher
I'm receiving an NoMethodError: undefined method
jobs' for CustomJob:Class` error message when I run my specs, and I can't figure out why. I've checked #2 which seemed to be a similar issue, but I'm not making that mistake, and I'm using the latest versions of rspec-sidekiq (v2.1.0), Sidekiq (v3.4.2) and RSpec (v3.3.0).
My code is as follows:
it 'should have enqueued CustomJob' do
x = 'something'
y = 'something else'
CustomJob.perform_later(x, y)
expect(CustomJob).to have_enqueued_job(x, y)
end
After running this spec, I'm receiving:
Failures:
1) CustomGateway should have enqueued CustomJob
Failure/Error: expect(CustomJob).to have_enqueued_job(x, y)
NoMethodError:
undefined method `jobs' for CustomJob:Class
Any ideas about what I might be doing wrong? I'm not calling a "jobs" method anywhere in my code.
I've included the rspec-sidekiq gem in my Gemfile, which seems to be the only configuration required to get this up and running
Matcher is pointless given that you can do...
expect(AwesomeJob).to have(1).jobs
# or
expect(AwesomeJob).to have(1).enqueued.jobs
Remove, or ideally keep with a message telling people to use the other syntax
I wanna test "sidekiq_retries_exhausted" in this class:
class PostListingsWorker
include Sidekiq::Worker
sidekiq_options :retry => 0
sidekiq_retries_exhausted do |msg|
NotifyMailer.warn_email(msg).deliver_now
end
def perform(params, fetch_time)
....
end
end
Here is my test:
it 'should send email when retries exhausted' do
msg = {error_message: 'Wrong', args: [{id: 1}]}.to_json
PostListingsWorker.within_sidekiq_retries_exhausted_block(msg) {
expect(PostListingsWorker).to receive(:"NotifyMailer.warn_email().deliver_now").with(msg)
}
end
But it doesn't work.Here is my log:
Failure/Error: expect(PostListingsWorker).to > >
receive(:"NotifyMailer.warn_email().deliver_now").with(:msg)
PostListingsWorker does not implement: NotifyMailer.warn_email().deliver_now
So,is there any way to test a method belong to another class during "sidekiq_retries_exhausted"?
I'm running my specs with real Redis (via https://github.com/guilleiguaran/fakeredis), with Sidekiq::Testing.disable!
and with this little hack to make thing working.
I think the problem is that have_enqueued_job
doesn't look for jobs in Sidekiq::Queue
object but rather Worker.jobs
array. (it's my guess)
MyWorker.perform_async 'SuperAwesome'
=> "6983e6462239240363aa9280"
to ensure it's actually inside sidekiq queue I'll try:
Sidekiq::Queue.new('my que').to_a.first
=> #<Sidekiq::Job:0x007fb3ffdd4dd8
@item=
{"class"=>"MyWorker",
"args"=>["SuperAwesome"],
"queue"=>"my que",
"jid"=>"6983e6462239240363aa9280",
"created_at"=>1441896216.818053,
"enqueued_at"=>1441896216.818154},
@queue="leads",
@value= ...
Now let's run matcher:
expect(MyWorker).to have_enqueued_job('SuperAwesome')
RSpec::Expectations::ExpectationNotMetError: expected to have an enqueued MyWorker job with arguments ["SuperAwesome"]
found: []
What exactly we might do here? That is when sidekiq
is pushing to redis
. Here is one of the matcher changed to handle such case. Is it a right thing to do?
Hello~
after I installed this gem when executing guard it throws out an error as below:
undefined method `client_push' for module `Sidekiq::Worker::ClassMethods' (NameError)
I look it up on google and find this
so I think it is because there is a line of
require File.expand_path("../../config/environment", __FILE__)
in my code that cause this error, so is there a way I could put
require 'sidekiq/testing'
after this line while using this gem?
Thanks. :)
I'm getting an ArgumentError exception when my specs try to instantiate an instance of Sidekiq::Batch::Status
.
With one argument, I get ArgumentError Exception: wrong number of arguments (given 0, expected 2)
With 2+ arguments I get ArgumentError Exception: Wrong number of arguments. Expected 1, got n#
I placed a few break points in the file pertaining to batches and I see the call to the NullBatch initializer is called but not the call to NullStatus. Has anyone ever seen this type of behavior?
I also notice that the BatchStatus object only takes one argument, a bid, but the NullStatus takes both a bid and a callback. How does this work?
I have found this code on the Sidekiq page, but it has since been removed:
Collector.should have_queued_job_at(date_2,1)
Is this have_queued_job_at method part of the gem? it doesn't seem to be recognised. Is there any way to test the time that the job has been rescheduled to?
Not sure if it's just latest release, but even just putting rspec-sidekiq in my gem file causes my 'perform_async' functions to stop enqueue Sidekiq jobs. When I monitor Redis, I can see that the entires aren't even being made in the Redis database. This while using my app in development, not while running specs.
If I remove the gem from Gemfile and re-bundle, everything works great.
Construct specs to verify proper function of matchers
I get this error when I try to use this API. I'm afraid I'm using it incorrectly.
UnlockContentJob.perform_later(1, 2, 3)
expect(UnlockContentJob).to have_enqueued_job(1, 2, 3)
Failure/Error: expect(UnlockContentJob).to have_enqueued_job(1, 2, 3)
ArgumentError:
wrong number of arguments (3 for 0..1)
The docs show multiple args:
expect(AwesomeJob).to have_enqueued_job('Awesome', true)
UnlockContentJob
is an ActiveJob subclass. Could that be why? Do I need to do something special to set up this gem for ActiveJob? It looked like the adapter was set by the gem.
Thanks for these handing testing additions for sidekiq!
RSpec 3.1 was released in September. Any chance we can get an updated release of rspec-sidekiq?
Given this worker:
class AwesomeJob
include Sidekiq::Worker
sidekiq_options :queue => :download
def perform
end
end
When I run the example listed in the README expect(AwesomeJob).to be_processed_in :download
, I get the following error:
Failure/Error: expect(AwesomeJob).to be_processed_in :download
NoMethodError:
undefined method `get_sidekiq_options' for Class:Class
# ./lib/rspec/sidekiq/matchers/be_processed_in.rb:23:in `matches?'
If I updated the test to say expect(AwesomeJob.new).to be_processed_in :download
, though, then it passes. Am I doing something wrong, or is there a problem with the way that rspec-sidekiq handles the expect syntax?
If I use the older syntax it { should be_processed_in :download }
, the test passes.
hopefully, this will make the transition to rspec 3 smoother :-)
Once I upped to Sidekiq Pro, the rspec-sidekiq gem started borking all of my tests with the following error:
Failure/Error: Unable to find matching line from backtrace
NoMethodError:
undefined method `stub' for Sidekiq::Batch:Class
Not sure what the issue is, I will see if I can figure it out, but any help would def be appreciated.
I started getting this error after migration to rails 4.1.0
I use sidekiq-pro
bundle exec rake db:create db:schema:load --trace
rake aborted!
NoMethodError: undefined method `configure' for RSpec:Module
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rspec-sidekiq-1.0.0/lib/rspec/sidekiq/batch.rb:31:in `<top (required)>'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:247:in `require'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:247:in `block in require'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:232:in `load_dependency'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:247:in `require'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rspec-sidekiq-1.0.0/lib/rspec-sidekiq.rb:3:in `<top (required)>'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `require'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:72:in `each'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:72:in `block in require'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:61:in `each'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:61:in `require'
/home/ubuntu/.rvm/gems/ruby-2.0.0-p353@global/gems/bundler-1.6.2/lib/bundler.rb:132:in `require'
/home/ubuntu/seo_platform/config/application.rb:14:in `<top (required)>'
/home/ubuntu/seo_platform/Rakefile:4:in `require'
/home/ubuntu/seo_platform/Rakefile:4:in `<top (required)>'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/rake_module.rb:28:in `load'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/rake_module.rb:28:in `load_rakefile'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:677:in `raw_load_rakefile'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:94:in `block in load_rakefile'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:176:in `standard_exception_handling'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:93:in `load_rakefile'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:77:in `block in run'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:176:in `standard_exception_handling'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/lib/rake/application.rb:75:in `run'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/gems/rake-10.2.2/bin/rake:33:in `<top (required)>'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/bin/rake:23:in `load'
/home/ubuntu/seo_platform/vendor/bundle/ruby/2.0.0/bin/rake:23:in `<main>'
Any thoughts?
I'm on Rails 4.0 RC1 with sidekiq 2.11.2 and rspec 2.13.1
When I include the gem:
group :test do
gem "rspec-sidekiq"
end
Rspec won't start and returns:
..../sidekiq-2.11.2/lib/sidekiq/testing.rb:5:in alias_method': undefined method
raw_push' for class `Class' (NameError)
I have not included rspec-sidekiq or sidekiq/testing in my spec_helper. Any Ideas?
When I bump rspec-rails to ~>3.2.1
in my gemfile I get dependency conflicts:
Bundler could not find compatible versions for gem "rspec-mocks":
In Gemfile:
rspec-rails (~> 3.2.1) ruby depends on
rspec-mocks (~> 3.2.0) ruby
rspec-sidekiq (~> 2.0.0) ruby depends on
rspec (>= 3.0.0, ~> 3.0) ruby depends on
rspec-mocks (~> 3.1.0) ruby
This is probably related to issue #13
You are using an old or stdlib version of json gem
Please upgrade to the recent version by adding this to your Gemfile:
gem 'json', '~> 1.7.7'
Hello developer
Hello please review the following patch.
rspec-sidekiq version 0.3.0
Or could you tell me how to use be_processed_in?
Best regards.
diff --git a/lib/rspec/sidekiq/matchers/be_processed_in.rb b/lib/rspec/sidekiq/matchers/be_processed_in.rb
index ced8114..68a0095 100644
--- a/lib/rspec/sidekiq/matchers/be_processed_in.rb
+++ b/lib/rspec/sidekiq/matchers/be_processed_in.rb
@@ -19,7 +19,7 @@ module RSpec
end
def matches? job
- @klass = job.class
+ @klass = job
@actual = @klass.get_sidekiq_options["queue"]
@actual == @expected
end
@@ -30,4 +30,4 @@ module RSpec
end
end
end
-end
\ No newline at end of file
+end
I got the following error
1) MyWorker
Failure/Error: it { expect(MyWorker).to be_processed_in :test }
NoMethodError:
undefined method `get_sidekiq_options' for Class:Class
describe MyWorker do
before { MyWorker.perform_async('foo', 'bar') }
it { expect(MyWorker).to be_processed_in :test }
end
In rspec-rails
we implemented support for asserting on wether or not an ActiveJob
has been queued, unfortunately we used have_enqueued_job
as the name for this matcher as we were unaware of this gem. This means that rspec-sidekiq
will now clash with rspec-rails
.
Given that our matcher is more generic I propose that the have_enqueued_job
matcher in rspec-sidekiq
be renamed to have_enqueued_sidekiq_job
and then aliased back to have_enqueued_job
when it's not otherwise defined. (We use the alias trick a fair bit in rspec-expectations
to provide extra grammar for matchers so it's a pretty accepted technique).
I'd be happy to work on a PR for this if it's acceptable to you :)
Loosen dependency to take into account RSpec 3.x
Provide a full spec file example of how testing a job might look
Generally improve quality of README and maybe move example up etc
I can't figure out why #be_delayed matcher doesn't work for me :( Have the following code:
class SomeClass
def call
Object.delay.is_a?(Object)
end
end
With spec:
require 'rails_helper'
describe SomeClass do
subject { described_class.new }
it 'does something' do
subject.call
expect(Object.method(:is_a?)).to be_delayed
end
end
And running specs gives this:
10:58:11 - INFO - Running: spec/services/some_class_spec.rb
[rspec-sidekiq] WARNING! Sidekiq will *NOT* process jobs in this environment. See https://github.com/philostler/rspec-sidekiq/wiki/FAQ-&-Troubleshooting
SomeClass
does something (FAILED - 1)
Failures:
1) SomeClass does something
Failure/Error: expect(Object.method(:is_a?)).to be_delayed
expected Object.is_a? to be delayed
# ./spec/services/some_class_spec.rb:8:in `block (2 levels) in <top (required)>'
# ./spec/rails_helper.rb:61:in `block (3 levels) in <top (required)>'
# ./spec/rails_helper.rb:60:in `block (2 levels) in <top (required)>'
Any suggestions?
TOC needs updating along with a longer description
Hey!
Trying to get rspec-sidekiq to be working.
I was reading your initialization documents. I was under the impression that expect takes in a block instead of being called as a method.
expect { AwesomeJob }
instead of expect( AwesomeJob )
Using expect as a method causes a ArgumentError (1 for 0).
If i make that assumption, when i call the expect job, i get the following error,
undefined method
jobs' for #Proc:0x007fb7648e8578`.
Any ideas? Thanks!
expect(Car.method :open).to be_delayed(car.id)
raises TypeError: allocator undefined for Proc
exception.
It happened with rspec-sidekiq 2.0.0 and upgrading to 2.2.0 hasn't resolved the issue.
in the code below, I am trying to test for a potential race condition in sidekiqPro's Batch, and attempting to write a unit test for that condition. To do this, the Batch::Status for the batch needs to return something reasonable for the "total" attribute. right now, "total" just returns self(!). really threw me for a loop.
class SearchWorker < BaseWorker
def perform(search_id, user_id, channel_id)
# ...
sites = search.deserialize_courts
batch = Sidekiq::Batch.new
batch.jobs do
sites.each do |site|
SiteSearchWorker.perform_async(site.id, search_id, user_id, channel_id)
end
end
status = Sidekiq::Batch::Status.new(batch.bid)
# status.join works
status.join
# status.total returns a NullStatus instead of an integer
if (status.total < sites.length)
awesome_print status.total
message = "Sidekiq Batch status total (#{status.total}) was less than sites searched (#{sites.length})!!!"
raise message
end
end
I'll see if I can come up with a pull request, but any suggestions in the meantime?
Thanks!
if I'm using rspec-rails, the rspec gem is never pulled in.. using this gem shouldn't pull it in either.
I've had a number of issues where Sidekiq has stopped processing jobs in development mode. These all boiled down to people including rspec-sidekiq in the development group in their Gemfile. Could you please print a warning on bootup in the development environment since it is probably not what people want?
Bonus points: allow the user to disable the warning if they know they actually want to do this for some odd reason.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.