database_cleaner-spanner 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.rspec +3 -0
- data/.standard.yml +3 -0
- data/CHANGELOG.md +5 -0
- data/CODE_OF_CONDUCT.md +84 -0
- data/Gemfile +12 -0
- data/README.md +106 -0
- data/Rakefile +10 -0
- data/database_cleaner-spanner.gemspec +34 -0
- data/lib/database_cleaner/spanner/deletion.rb +119 -0
- data/lib/database_cleaner/spanner/table_dependency.rb +73 -0
- data/lib/database_cleaner/spanner/version.rb +7 -0
- data/lib/database_cleaner/spanner.rb +7 -0
- data/lib/database_cleaner-spanner.rb +1 -0
- data/sig/database_cleaner/spanner.rbs +6 -0
- metadata +90 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 2c8d719d3f246b5bda9a82752ffbea98675e9776f10310eea0b94ef3a3f44a71
|
4
|
+
data.tar.gz: 6bff1b7b11584e8c81cfb0b26ab0675b217c0a8e5888c0e901713f12feafc89e
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 1a221c3bc36d5280d1b11588d30e3cb7ad855eb7589feb5f59b0ebaaeb66a4c9ee066f21402aa0ea33a7dfbe69acde970919ac8cedbc6ad779a9459f8fadc390
|
7
|
+
data.tar.gz: c42d9eb77c819a65d241614395a42ae8bb1a409dcbc91fe557dea8daa34308b6ee37fb79f35879f5405b3f386b6ce3c6f3f4be1e7126dba745c1b41d1c910b8d
|
data/.rspec
ADDED
data/.standard.yml
ADDED
data/CHANGELOG.md
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,84 @@
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
2
|
+
|
3
|
+
## Our Pledge
|
4
|
+
|
5
|
+
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
|
6
|
+
|
7
|
+
We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
|
8
|
+
|
9
|
+
## Our Standards
|
10
|
+
|
11
|
+
Examples of behavior that contributes to a positive environment for our community include:
|
12
|
+
|
13
|
+
* Demonstrating empathy and kindness toward other people
|
14
|
+
* Being respectful of differing opinions, viewpoints, and experiences
|
15
|
+
* Giving and gracefully accepting constructive feedback
|
16
|
+
* Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience
|
17
|
+
* Focusing on what is best not just for us as individuals, but for the overall community
|
18
|
+
|
19
|
+
Examples of unacceptable behavior include:
|
20
|
+
|
21
|
+
* The use of sexualized language or imagery, and sexual attention or
|
22
|
+
advances of any kind
|
23
|
+
* Trolling, insulting or derogatory comments, and personal or political attacks
|
24
|
+
* Public or private harassment
|
25
|
+
* Publishing others' private information, such as a physical or email
|
26
|
+
address, without their explicit permission
|
27
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
28
|
+
professional setting
|
29
|
+
|
30
|
+
## Enforcement Responsibilities
|
31
|
+
|
32
|
+
Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful.
|
33
|
+
|
34
|
+
Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate.
|
35
|
+
|
36
|
+
## Scope
|
37
|
+
|
38
|
+
This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event.
|
39
|
+
|
40
|
+
## Enforcement
|
41
|
+
|
42
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at nownabe@gmail.com. All complaints will be reviewed and investigated promptly and fairly.
|
43
|
+
|
44
|
+
All community leaders are obligated to respect the privacy and security of the reporter of any incident.
|
45
|
+
|
46
|
+
## Enforcement Guidelines
|
47
|
+
|
48
|
+
Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct:
|
49
|
+
|
50
|
+
### 1. Correction
|
51
|
+
|
52
|
+
**Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community.
|
53
|
+
|
54
|
+
**Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested.
|
55
|
+
|
56
|
+
### 2. Warning
|
57
|
+
|
58
|
+
**Community Impact**: A violation through a single incident or series of actions.
|
59
|
+
|
60
|
+
**Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban.
|
61
|
+
|
62
|
+
### 3. Temporary Ban
|
63
|
+
|
64
|
+
**Community Impact**: A serious violation of community standards, including sustained inappropriate behavior.
|
65
|
+
|
66
|
+
**Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban.
|
67
|
+
|
68
|
+
### 4. Permanent Ban
|
69
|
+
|
70
|
+
**Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals.
|
71
|
+
|
72
|
+
**Consequence**: A permanent ban from any sort of public interaction within the community.
|
73
|
+
|
74
|
+
## Attribution
|
75
|
+
|
76
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0,
|
77
|
+
available at https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
|
78
|
+
|
79
|
+
Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity).
|
80
|
+
|
81
|
+
[homepage]: https://www.contributor-covenant.org
|
82
|
+
|
83
|
+
For answers to common questions about this code of conduct, see the FAQ at
|
84
|
+
https://www.contributor-covenant.org/faq. Translations are available at https://www.contributor-covenant.org/translations.
|
data/Gemfile
ADDED
data/README.md
ADDED
@@ -0,0 +1,106 @@
|
|
1
|
+
# Database Claner Adapter for Cloud Spanner
|
2
|
+
|
3
|
+
Clean your Cloud Spanner databases with Database Cleaner.
|
4
|
+
|
5
|
+
See also [https://github.com/DatabaseCleaner/database_cleaner](https://github.com/DatabaseCleaner/database_cleaner) for more information.
|
6
|
+
|
7
|
+
## Motivation
|
8
|
+
|
9
|
+
* You cannot use [rspec-rails's `use_transactional_fixtures` option](https://relishapp.com/rspec/rspec-rails/v/6-0/docs/transactions) for Cloud Spanner because
|
10
|
+
[ActiveRecord Cloud Spanner Adapter](https://github.com/googleapis/ruby-spanner-activerecord) doesn't support nested transactions.
|
11
|
+
* [database_cleaner-active_record](https://github.com/DatabaseCleaner/database_cleaner-active_record) doesn't support Cloud Spanner perfectly.
|
12
|
+
* Transaction strategy cannot be used for the same reason as the `use_transactional_fixtures` option.
|
13
|
+
* Truncation strategy isn't available because Cloud Spanner doesn't support `TRUNCATE` statement.
|
14
|
+
* Deletion strategy is incompatible with Cloud Spanner because `DELETE FROM <table>` statement executed by the deletion strategy doesn't work on Cloud Spanner.
|
15
|
+
* Cloud Spanner is sometimes used with [Spanner Client](https://github.com/googleapis/ruby-spanner) instead of ActiveRecord.
|
16
|
+
* If tables are interleaved, the order of deletion needs to be considered.
|
17
|
+
* If tables has foreign key constraints, the order of deletion needs to be considered.
|
18
|
+
|
19
|
+
The core ideas of database_cleaner-spanner are:
|
20
|
+
|
21
|
+
* no dependence on ActiveRecord
|
22
|
+
* consider deletion orders based on actual schema
|
23
|
+
|
24
|
+
**NOTE:** This gem determines deletion orders based on dependency graph of tables using the topological sort algorithm, which means `only` option and `except` option don't guarantees removal of as many tables as dependencies allow.
|
25
|
+
|
26
|
+
## Installation
|
27
|
+
|
28
|
+
```ruby
|
29
|
+
# Gemfile
|
30
|
+
group :test do
|
31
|
+
gem "database_cleaner-spanner"
|
32
|
+
end
|
33
|
+
```
|
34
|
+
|
35
|
+
## Example
|
36
|
+
|
37
|
+
Configuration for RSpec on Rails:
|
38
|
+
|
39
|
+
```ruby
|
40
|
+
# spec/rails_helper.rb
|
41
|
+
|
42
|
+
RSpec.configure do |config|
|
43
|
+
config.use_transactional_fixtures = false
|
44
|
+
|
45
|
+
config.around(:each) do |example|
|
46
|
+
DatabaseCleaner[:spanner].cleaning do
|
47
|
+
example.run
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
```
|
52
|
+
|
53
|
+
## Supported strategies
|
54
|
+
|
55
|
+
The Cloud Spanner adapter has only the deletion strategy.
|
56
|
+
|
57
|
+
## Strategy configuration options
|
58
|
+
|
59
|
+
* `:cache_tables` - When set to `true`, the list of tables to delete and the deletion orders will be
|
60
|
+
read from the Cloud Spanner once, otherwise they will be read before each deletion. Defaults to
|
61
|
+
`true`.
|
62
|
+
|
63
|
+
## Adapter configuration options
|
64
|
+
|
65
|
+
You need to specify instance and database, or to pass an instance of Spanner client.
|
66
|
+
If you're using ActiveRecord, you can use database name on ActiveRecord.
|
67
|
+
This adapter tries to get database configurations from ActiveRecord.
|
68
|
+
|
69
|
+
```ruby
|
70
|
+
# Specify instance and database with default credentials and project ID.
|
71
|
+
DatabaseCleaner[:spanner].db = {
|
72
|
+
instance_id: "my-instance",
|
73
|
+
database_id: "my-database",
|
74
|
+
}
|
75
|
+
|
76
|
+
# In addition, specify project ID and credentials.
|
77
|
+
DatabaseCleaner[:spanner].db = {
|
78
|
+
credentials: "/path/to/key.json",
|
79
|
+
project_id: "my-project",
|
80
|
+
instance_id: "my-instance",
|
81
|
+
database_id: "my-database",
|
82
|
+
}
|
83
|
+
|
84
|
+
# ActiveRecord database name
|
85
|
+
DatabaseCleaner[:spanner].db = "secondary"
|
86
|
+
|
87
|
+
# Spanner client object
|
88
|
+
DatabaseCleaner[:spanner].db =
|
89
|
+
Google::Cloud::Spanner.new.client("my-instance", "my-database")
|
90
|
+
```
|
91
|
+
|
92
|
+
See [Spanner client reference](https://googleapis.dev/ruby/google-cloud-spanner/latest/Google/Cloud/Spanner.html#new-class_method) for more database options.
|
93
|
+
|
94
|
+
## Development
|
95
|
+
|
96
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
97
|
+
|
98
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
99
|
+
|
100
|
+
## Contributing
|
101
|
+
|
102
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/nownabe/database_cleaner-spanner. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/nownabe/database_cleaner-spanner/blob/main/CODE_OF_CONDUCT.md).
|
103
|
+
|
104
|
+
## Code of Conduct
|
105
|
+
|
106
|
+
Everyone interacting in the DatabaseCleaner::Spanner project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/nownabe/database_cleaner-spanner/blob/main/CODE_OF_CONDUCT.md).
|
data/Rakefile
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "lib/database_cleaner/spanner/version"
|
4
|
+
|
5
|
+
Gem::Specification.new do |spec|
|
6
|
+
spec.name = "database_cleaner-spanner"
|
7
|
+
spec.version = DatabaseCleaner::Spanner::VERSION
|
8
|
+
spec.authors = ["nownabe"]
|
9
|
+
spec.email = ["nownabe@gmail.com"]
|
10
|
+
|
11
|
+
spec.summary = "Strategies for cleaning tables on Cloud Spanner. Can be used to ensure a clean state for testing."
|
12
|
+
spec.description = "Strategies for cleaning tables on Cloud Spanner. Can be used to ensure a clean state for testing."
|
13
|
+
spec.homepage = "https://github.com/nownabe/database_cleaner-spanner"
|
14
|
+
spec.license = "MIT"
|
15
|
+
spec.required_ruby_version = ">= 2.6.0"
|
16
|
+
|
17
|
+
spec.metadata["homepage_uri"] = spec.homepage
|
18
|
+
spec.metadata["source_code_uri"] = spec.homepage
|
19
|
+
spec.metadata["changelog_uri"] = "#{spec.homepage}/"
|
20
|
+
|
21
|
+
# Specify which files should be added to the gem when it is released.
|
22
|
+
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
23
|
+
spec.files = Dir.chdir(File.expand_path(__dir__)) do
|
24
|
+
`git ls-files -z`.split("\x0").reject do |f|
|
25
|
+
(f == __FILE__) || f.match(%r{\A(?:(?:bin|test|spec|features)/|\.(?:git|travis|circleci)|appveyor)})
|
26
|
+
end
|
27
|
+
end
|
28
|
+
spec.bindir = "exe"
|
29
|
+
spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
|
30
|
+
spec.require_paths = ["lib"]
|
31
|
+
|
32
|
+
spec.add_dependency "google-cloud-spanner", "~> 2.10"
|
33
|
+
spec.add_dependency "database_cleaner-core", "~> 2.0.0"
|
34
|
+
end
|
@@ -0,0 +1,119 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "database_cleaner/strategy"
|
4
|
+
require "database_cleaner/spanner/table_dependency"
|
5
|
+
|
6
|
+
module DatabaseCleaner
|
7
|
+
module Spanner
|
8
|
+
class Deletion < Strategy
|
9
|
+
SQL = <<~SQL
|
10
|
+
WITH References AS (
|
11
|
+
SELECT
|
12
|
+
ccu.TABLE_NAME AS TABLE_NAME
|
13
|
+
, tc.TABLE_NAME AS referenced_by
|
14
|
+
FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS AS tc
|
15
|
+
INNER JOIN INFORMATION_SCHEMA.CONSTRAINT_COLUMN_USAGE AS ccu USING (CONSTRAINT_NAME)
|
16
|
+
WHERE
|
17
|
+
CONSTRAINT_TYPE = "FOREIGN KEY"
|
18
|
+
AND tc.TABLE_NAME <> ccu.TABLE_NAME
|
19
|
+
)
|
20
|
+
SELECT
|
21
|
+
t.TABLE_NAME AS table_name
|
22
|
+
, children.TABLE_NAME AS child_table_name
|
23
|
+
, children.ON_DELETE_ACTION AS delete_action
|
24
|
+
, r.referenced_by AS referenced_by
|
25
|
+
FROM INFORMATION_SCHEMA.TABLES AS t
|
26
|
+
LEFT JOIN INFORMATION_SCHEMA.TABLES AS children
|
27
|
+
ON t.TABLE_NAME = children.PARENT_TABLE_NAME
|
28
|
+
LEFT JOIN References AS r
|
29
|
+
ON t.TABLE_NAME = r.table_name
|
30
|
+
WHERE t.TABLE_TYPE = "BASE TABLE"
|
31
|
+
SQL
|
32
|
+
|
33
|
+
def initialize(
|
34
|
+
only: [],
|
35
|
+
except: [],
|
36
|
+
cache_tables: true
|
37
|
+
)
|
38
|
+
@only = only
|
39
|
+
@except = except
|
40
|
+
@cache_tables = cache_tables
|
41
|
+
|
42
|
+
@deletable_tables = {}
|
43
|
+
end
|
44
|
+
|
45
|
+
def clean
|
46
|
+
sorted_table_groups.each do |group|
|
47
|
+
clean_table_group(group)
|
48
|
+
end
|
49
|
+
end
|
50
|
+
|
51
|
+
private
|
52
|
+
|
53
|
+
def clean_table_group(group)
|
54
|
+
group.each do |table|
|
55
|
+
client.delete(table) if deletable?(table)
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
def deletable?(table)
|
60
|
+
return true if @only.empty? && @except.empty?
|
61
|
+
|
62
|
+
return @deletable_tables[table] if @deletable_tables.key?(table)
|
63
|
+
|
64
|
+
@deletable_tables[table] =
|
65
|
+
if @only.empty?
|
66
|
+
!@except.include?(table)
|
67
|
+
else
|
68
|
+
(@only - @except).include?(table)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
def sorted_table_groups
|
73
|
+
return @sorted_table_groups if @cache_tables && @sorted_table_groups
|
74
|
+
|
75
|
+
dep = TableDependency.new
|
76
|
+
result = client.execute_query(SQL)
|
77
|
+
|
78
|
+
result.rows.each do |row|
|
79
|
+
dep.add_child(row[:table_name], row[:child_table_name])
|
80
|
+
dep.add_child(row[:table_name], row[:referenced_by])
|
81
|
+
end
|
82
|
+
|
83
|
+
@sorted_table_groups = dep.divide.map(&:tsort)
|
84
|
+
end
|
85
|
+
|
86
|
+
def client
|
87
|
+
@client ||=
|
88
|
+
if db.is_a?(Google::Cloud::Spanner::Client)
|
89
|
+
db
|
90
|
+
elsif db.is_a?(Hash)
|
91
|
+
Google::Cloud::Spanner.new(
|
92
|
+
project_id: db[:project_id],
|
93
|
+
credentials: db[:credentials]
|
94
|
+
).client(db[:instance_id], db[:database_id])
|
95
|
+
else
|
96
|
+
configure_client_from_active_record(db)
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
def configure_client_from_active_record(name)
|
101
|
+
# "primary" is hardcoded in ActiveRecord
|
102
|
+
# https://github.com/rails/rails/blob/v7.0.4/activerecord/lib/active_record/database_configurations.rb
|
103
|
+
name = "primary" if name == :default
|
104
|
+
|
105
|
+
# DB config from ActiveRecord
|
106
|
+
config = ActiveRecord::Base.configurations.configs_for(name: name.to_s).configuration_hash
|
107
|
+
|
108
|
+
# Keep metadata tables
|
109
|
+
@except << ActiveRecord::SchemaMigration.table_name # schema_migrations
|
110
|
+
@except << ActiveRecord::Base.internal_metadata_table_name # ar_internal_metadata
|
111
|
+
|
112
|
+
Google::Cloud::Spanner.new(
|
113
|
+
project_id: config[:project],
|
114
|
+
credentials: config[:credentials]
|
115
|
+
).client(config[:instance], config[:database])
|
116
|
+
end
|
117
|
+
end
|
118
|
+
end
|
119
|
+
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
require "set"
|
2
|
+
require "tsort"
|
3
|
+
|
4
|
+
module DatabaseCleaner
|
5
|
+
module Spanner
|
6
|
+
class TableDependency < Hash
|
7
|
+
include TSort
|
8
|
+
|
9
|
+
def initialize
|
10
|
+
@parents = Hash.new { |h, k| h[k] = Set.new }
|
11
|
+
end
|
12
|
+
|
13
|
+
def add_child(parent, child)
|
14
|
+
store(parent, Set.new) unless key?(parent)
|
15
|
+
|
16
|
+
return if child.nil?
|
17
|
+
|
18
|
+
store(child, Set.new) unless key?(child)
|
19
|
+
|
20
|
+
fetch(parent).add(child)
|
21
|
+
|
22
|
+
@parents[child].add(parent)
|
23
|
+
end
|
24
|
+
|
25
|
+
def add_children(parent, children)
|
26
|
+
store(parent, children || Set.new)
|
27
|
+
children.each { |child| @parents[child].add(parent) }
|
28
|
+
end
|
29
|
+
|
30
|
+
def divide
|
31
|
+
groups = []
|
32
|
+
visited = Set.new
|
33
|
+
|
34
|
+
each_table do |table|
|
35
|
+
next if visited.include?(table)
|
36
|
+
|
37
|
+
group = TableDependency.new
|
38
|
+
dfs(table, group, visited)
|
39
|
+
groups << group
|
40
|
+
end
|
41
|
+
|
42
|
+
groups
|
43
|
+
end
|
44
|
+
|
45
|
+
alias_method :each_table, :each_key
|
46
|
+
|
47
|
+
def tsort_each_child(node, &block)
|
48
|
+
fetch(node).each(&block)
|
49
|
+
end
|
50
|
+
|
51
|
+
alias_method :tsort_each_node, :each_key
|
52
|
+
|
53
|
+
private
|
54
|
+
|
55
|
+
def dfs(table, group, visited)
|
56
|
+
visited.add(table)
|
57
|
+
children = fetch(table)
|
58
|
+
group.add_children(table, children)
|
59
|
+
|
60
|
+
related_tables = if @parents.key?(table)
|
61
|
+
children + @parents[table]
|
62
|
+
else
|
63
|
+
children
|
64
|
+
end
|
65
|
+
|
66
|
+
related_tables.each do |table|
|
67
|
+
next if visited.include?(table)
|
68
|
+
dfs(table, group, visited)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
@@ -0,0 +1 @@
|
|
1
|
+
require "database_cleaner/spanner"
|
metadata
ADDED
@@ -0,0 +1,90 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: database_cleaner-spanner
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- nownabe
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2022-11-13 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: google-cloud-spanner
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '2.10'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '2.10'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: database_cleaner-core
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 2.0.0
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 2.0.0
|
41
|
+
description: Strategies for cleaning tables on Cloud Spanner. Can be used to ensure
|
42
|
+
a clean state for testing.
|
43
|
+
email:
|
44
|
+
- nownabe@gmail.com
|
45
|
+
executables: []
|
46
|
+
extensions: []
|
47
|
+
extra_rdoc_files: []
|
48
|
+
files:
|
49
|
+
- ".rspec"
|
50
|
+
- ".standard.yml"
|
51
|
+
- CHANGELOG.md
|
52
|
+
- CODE_OF_CONDUCT.md
|
53
|
+
- Gemfile
|
54
|
+
- README.md
|
55
|
+
- Rakefile
|
56
|
+
- database_cleaner-spanner.gemspec
|
57
|
+
- lib/database_cleaner-spanner.rb
|
58
|
+
- lib/database_cleaner/spanner.rb
|
59
|
+
- lib/database_cleaner/spanner/deletion.rb
|
60
|
+
- lib/database_cleaner/spanner/table_dependency.rb
|
61
|
+
- lib/database_cleaner/spanner/version.rb
|
62
|
+
- sig/database_cleaner/spanner.rbs
|
63
|
+
homepage: https://github.com/nownabe/database_cleaner-spanner
|
64
|
+
licenses:
|
65
|
+
- MIT
|
66
|
+
metadata:
|
67
|
+
homepage_uri: https://github.com/nownabe/database_cleaner-spanner
|
68
|
+
source_code_uri: https://github.com/nownabe/database_cleaner-spanner
|
69
|
+
changelog_uri: https://github.com/nownabe/database_cleaner-spanner/
|
70
|
+
post_install_message:
|
71
|
+
rdoc_options: []
|
72
|
+
require_paths:
|
73
|
+
- lib
|
74
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
75
|
+
requirements:
|
76
|
+
- - ">="
|
77
|
+
- !ruby/object:Gem::Version
|
78
|
+
version: 2.6.0
|
79
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
80
|
+
requirements:
|
81
|
+
- - ">="
|
82
|
+
- !ruby/object:Gem::Version
|
83
|
+
version: '0'
|
84
|
+
requirements: []
|
85
|
+
rubygems_version: 3.3.7
|
86
|
+
signing_key:
|
87
|
+
specification_version: 4
|
88
|
+
summary: Strategies for cleaning tables on Cloud Spanner. Can be used to ensure a
|
89
|
+
clean state for testing.
|
90
|
+
test_files: []
|