on_exit(fn -> File.rm_rf!("test/instance_static/emoji/finmoji") end)
end
+ test "install local emoji pack" do
+ assert capture_io(fn ->
+ Emoji.run([
+ "get-packs",
+ "local",
+ "--manifest",
+ "test/instance_static/local_pack/manifest.json"
+ ])
+ end) =~ "Writing pack.json for"
+
+ on_exit(fn -> File.rm_rf!("test/instance_static/emoji/local") end)
+ end
+
test "pack not found" do
mock(fn
%{
assert File.exists?(files_json)
on_exit(fn ->
- File.rm_rf!(pack_json)
- File.rm_rf!(files_json)
+ File.rm!(pack_json)
+ File.rm!(files_json)
end)
end
assert captured =~ "#{pack_json} has been updated with the pack2 pack"
on_exit(fn ->
- File.rm_rf!(pack_json)
- File.rm_rf!(files_json)
+ File.rm!(pack_json)
+ File.rm!(files_json)
end)
end
end