air_test 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/exe/air_test +64 -0
  3. data/lib/air_test/version.rb +1 -1
  4. metadata +7 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c4921bb57f9c5c1f8d720c7fe14ddb50b6ab1959a5fb16521918d05083c65b90
4
- data.tar.gz: a4fcbc657772c9bf9fa5ad50e61e37682681427b7788c78ba2c2d7ab54002ffe
3
+ metadata.gz: 26f6255268e954f779db9fd1f517565afea3a4c8e6a64c34796b13df95dedb62
4
+ data.tar.gz: 0d5c580cd9ea6997e2c7388e1e9c9dce7ffc863e5e713650e94204971a03b330
5
5
  SHA512:
6
- metadata.gz: 20aff8beca5a75f7465a4dbdf0e7a14f3ff6df85e4e73184ec967173a2f8ac43057a53f0bc96d310a095e45389ea5882510bb4ac29e131b9d375a440ce173aca
7
- data.tar.gz: 0de7e6835c9dde4bf40b713080befe07dea4d107044c1039a21c745caa09895a7c78dc994d49930064d534aaa9e3a103eead6cf8b7666ed9aed0001839ce5bbb
6
+ metadata.gz: ff3f31e9e880ae47460d8f4ed3f07ebc7c333533aa85cc6d40541729f65346c8a9d9052534d82f52a1c5e371b173feca5d73e886feb6ac3e716f350ce2a8e0f6
7
+ data.tar.gz: efa4d2033943a6b309a19b39aebd743f92e8e43c84df9cb0ae5d3e44d5f0a8aef4e946481ec97c996f36116c96e0f7d6cb40f4de926566be5d45208dc9833f90
data/exe/air_test ADDED
@@ -0,0 +1,64 @@
1
+ #!/usr/bin/env ruby
2
+ require 'fileutils'
3
+
4
+ GREEN = "\e[32m"
5
+ YELLOW = "\e[33m"
6
+ RED = "\e[31m"
7
+ CYAN = "\e[36m"
8
+ RESET = "\e[0m"
9
+
10
+ puts "#{CYAN}🚀 Initializing AirTest for your Rails project...#{RESET}\n"
11
+
12
+ initializer_path = "config/initializers/air_test.rb"
13
+ if File.exist?(initializer_path)
14
+ puts "#{YELLOW}⚠️ #{initializer_path} already exists. Skipping.#{RESET}"
15
+ else
16
+ FileUtils.mkdir_p(File.dirname(initializer_path))
17
+ File.write(initializer_path, <<~RUBY)
18
+ AirTest.configure do |config|
19
+ config.notion_token = ENV['NOTION_TOKEN']
20
+ config.notion_database_id = ENV['NOTION_DATABASE_ID']
21
+ config.github_token = ENV['GITHUB_BOT_TOKEN']
22
+ config.repo = 'your-org/your-repo' # format: 'organization/repo_name'
23
+ end
24
+ RUBY
25
+ puts "#{GREEN}✅ Created #{initializer_path}#{RESET}"
26
+ end
27
+
28
+ ['spec/features', 'spec/steps'].each do |dir|
29
+ if Dir.exist?(dir)
30
+ puts "#{YELLOW}⚠️ #{dir} already exists. Skipping.#{RESET}"
31
+ else
32
+ FileUtils.mkdir_p(dir)
33
+ puts "#{GREEN}✅ Created #{dir}/#{RESET}"
34
+ end
35
+ end
36
+
37
+ example_env = ".env.air_test.example"
38
+ if File.exist?(example_env)
39
+ puts "#{YELLOW}⚠️ #{example_env} already exists. Skipping.#{RESET}"
40
+ else
41
+ File.write(example_env, <<~ENV)
42
+ NOTION_TOKEN=your_notion_token
43
+ NOTION_DATABASE_ID=your_notion_database_id
44
+ GITHUB_BOT_TOKEN=your_github_token
45
+ ENV
46
+ puts "#{GREEN}✅ Created #{example_env}#{RESET}"
47
+ end
48
+
49
+ puts "\n🔎 Checking environment variables..."
50
+ missing = []
51
+ %w[NOTION_TOKEN NOTION_DATABASE_ID GITHUB_BOT_TOKEN].each do |var|
52
+ if ENV[var].nil? || ENV[var].empty?
53
+ puts "#{YELLOW}⚠️ #{var} is not set!#{RESET}"
54
+ missing << var
55
+ else
56
+ puts "#{GREEN}✅ #{var} is set#{RESET}"
57
+ end
58
+ end
59
+
60
+ puts "\n✨ All set! Next steps:"
61
+ puts " 1. Fill in your config/initializers/air_test.rb"
62
+ puts " 2. Add your tokens to .env or your environment"
63
+ puts " 3. Run: bundle exec rake air_test:generate_specs_from_notion"
64
+ puts "\nHappy testing! 🎉"
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module AirTest
4
- VERSION = "0.1.0"
4
+ VERSION = "0.1.2"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: air_test
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - julien bouland
@@ -13,7 +13,8 @@ description: Automate the generation of Turnip/RSpec specs from Notion tickets,
13
13
  branches, commits, pushes, and GitHub Pull Requests—all with a single Rake command.
14
14
  email:
15
15
  - bouland.julien@gmail.com
16
- executables: []
16
+ executables:
17
+ - air_test
17
18
  extensions: []
18
19
  extra_rdoc_files: []
19
20
  files:
@@ -24,6 +25,7 @@ files:
24
25
  - LICENSE.txt
25
26
  - README.md
26
27
  - Rakefile
28
+ - exe/air_test
27
29
  - lib/air_test.rb
28
30
  - lib/air_test/configuration.rb
29
31
  - lib/air_test/github_client.rb
@@ -33,12 +35,12 @@ files:
33
35
  - lib/air_test/version.rb
34
36
  - lib/tasks/air_test.rake
35
37
  - sig/air_test.rbs
36
- homepage: https://github.com/airtest-io/air_test
38
+ homepage: https://github.com/airtest-dev/airtest
37
39
  licenses:
38
40
  - MIT
39
41
  metadata:
40
- homepage_uri: https://github.com/airtest-io/air_test
41
- source_code_uri: https://github.com/airtest-io/air_test
42
+ homepage_uri: https://github.com/airtest-dev/airtest
43
+ source_code_uri: https://github.com/airtest-dev/airtest
42
44
  changelog_uri: https://github.com/airtest-io/air_test/blob/main/CHANGELOG.md
43
45
  rdoc_options: []
44
46
  require_paths: