Skip to content

Commit 0ab820f

Browse files
committed
js: remove marionette atom generation
1 parent 77b57ec commit 0ab820f

File tree

2 files changed

+0
-63
lines changed

2 files changed

+0
-63
lines changed

Rakefile

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -592,55 +592,6 @@ namespace :safari do
592592
]
593593
end
594594

595-
namespace :marionette do
596-
atoms_file = "build/javascript/marionette/atoms.js"
597-
func_lookup = {"//javascript/atoms/fragments:clear:firefox" => "clearElement",
598-
"//javascript/webdriver/atoms/fragments:get_attribute:firefox" => "getElementAttribute",
599-
"//javascript/webdriver/atoms/fragments:get_text:firefox" => "getElementText",
600-
"//javascript/atoms/fragments:is_enabled:firefox" => "isElementEnabled",
601-
"//javascript/webdriver/atoms/fragments:is_selected:firefox" => "isElementSelected",
602-
"//javascript/atoms/fragments:is_displayed:firefox" => "isElementDisplayed"}
603-
604-
# This task takes all the relevant Marionette atom dependencies
605-
# (listed in func_lookup) and concatenates them to a single atoms.js
606-
# file.
607-
#
608-
# The function names are defined in the func_lookup dictionary of
609-
# target to name.
610-
#
611-
# Instead of having this custom behaviour in Selenium, Marionette
612-
# should use the individually generated .js atom files directly in
613-
# the future.
614-
#
615-
# (See Mozilla bug 936204.)
616-
617-
desc "Generate Marionette atoms"
618-
task :atoms => func_lookup.keys do |task|
619-
b = StringIO.new
620-
b << File.read("javascript/marionette/COPYING") << "\n"
621-
b << "\n"
622-
b << "const EXPORTED_SYMBOLS = [\"atoms\"];" << "\n"
623-
b << "\n"
624-
b << "function atoms() {};" << "\n"
625-
b << "\n"
626-
627-
task.prerequisites.each do |target|
628-
out = Rake::Task[target].out
629-
atom = File.read(out).chop
630-
631-
b << "// target #{target}" << "\n"
632-
b << "atoms.#{func_lookup[target]} = #{atom};" << "\n"
633-
b << "\n"
634-
end
635-
636-
puts "Generating uberatoms file: #{atoms_file}"
637-
FileUtils.mkpath("build/javascript/marionette")
638-
File.open("build/javascript/marionette/atoms.js", "w+") do |h|
639-
h.write(b.string)
640-
end
641-
end
642-
end
643-
644595
task :authors do
645596
puts "Generating AUTHORS file"
646597
sh "(git log --use-mailmap --format='%aN <%aE>' ; cat .OLD_AUTHORS) | sort -uf > AUTHORS"

javascript/marionette/COPYING

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)