Skip to content

Commit

Permalink
Disable stickerpack resources and assertions for tests, as they are t…
Browse files Browse the repository at this point in the history
…oo flaky.

RELNOTES: None
PiperOrigin-RevId: 224426313
  • Loading branch information
sergiocampama committed Dec 7, 2018
1 parent 5910c11 commit a76180f
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 16 deletions.
1 change: 0 additions & 1 deletion test/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,6 @@ apple_multi_shell_test(
data = [
"//test/testdata/resources:resource_data_deps_ios",
],
flaky = 1,
shard_count = 5,
)

Expand Down
16 changes: 9 additions & 7 deletions test/ios_extension_resources_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,8 @@ ios_application(
ios_extension(
name = "ext",
app_icons = ["@build_bazel_rules_apple//test/testdata/resources:sticker_pack_ios"],
# TODO(b/120618397): Reenable the stickers.
# app_icons = ["@build_bazel_rules_apple//test/testdata/resources:sticker_pack_ios"],
bundle_id = "my.bundle.id.extension",
families = ["iphone"],
infoplists = ["Info-Ext.plist"],
Expand All @@ -177,12 +178,13 @@ EOF

do_build ios //app:app || fail "Should build"

assert_zip_contains "test-bin/app/app.ipa" \
"Payload/app.app/PlugIns/ext.appex/sticker_pack.stickerpack/Info.plist"
assert_zip_contains "test-bin/app/app.ipa" \
"Payload/app.app/PlugIns/ext.appex/sticker_pack.stickerpack/sequence.png"
assert_zip_contains "test-bin/app/app.ipa" \
"Payload/app.app/PlugIns/ext.appex/sticker_pack.stickerpack/sticker.png"
# TODO(b/120618397): Reenable these assertions.
# assert_zip_contains "test-bin/app/app.ipa" \
# "Payload/app.app/PlugIns/ext.appex/sticker_pack.stickerpack/Info.plist"
# assert_zip_contains "test-bin/app/app.ipa" \
# "Payload/app.app/PlugIns/ext.appex/sticker_pack.stickerpack/sequence.png"
# assert_zip_contains "test-bin/app/app.ipa" \
# "Payload/app.app/PlugIns/ext.appex/sticker_pack.stickerpack/sticker.png"
}

# Tests that a sticker pack application fails to build and emits a reasonable
Expand Down
19 changes: 11 additions & 8 deletions test/ios_imessage_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ ios_sticker_pack_extension(
infoplists = ["Info-Ext.plist"],
minimum_os_version = "10.0",
provisioning_profile = "@build_bazel_rules_apple//test/testdata/provisioning:integration_testing_ios.mobileprovision",
sticker_assets = ["@build_bazel_rules_apple//test/testdata/resources:sticker_pack_ios"],
# TODO(b/120618397): Reenable the stickers.
# sticker_assets = ["@build_bazel_rules_apple//test/testdata/resources:sticker_pack_ios"],
)
EOF
}
Expand Down Expand Up @@ -141,7 +142,8 @@ ios_sticker_pack_extension(
infoplists = ["Info-Ext.plist"],
minimum_os_version = "10.0",
provisioning_profile = "@build_bazel_rules_apple//test/testdata/provisioning:integration_testing_ios.mobileprovision",
sticker_assets = ["@build_bazel_rules_apple//test/testdata/resources:sticker_pack_ios"],
# TODO(b/120618397): Reenable the stickers.
# sticker_assets = ["@build_bazel_rules_apple//test/testdata/resources:sticker_pack_ios"],
)
EOF
}
Expand Down Expand Up @@ -176,12 +178,13 @@ function test_sticker_pack_builds_with_stickersiconset() {
do_build ios //app:app --define=apple.experimental.bundling=1 \
|| fail "Should build"

assert_zip_contains "test-bin/app/app.ipa" \
"Payload/app.app/PlugIns/stickerpack.appex/sticker_pack.stickerpack/Info.plist"
assert_zip_contains "test-bin/app/app.ipa" \
"Payload/app.app/PlugIns/stickerpack.appex/sticker_pack.stickerpack/sequence.png"
assert_zip_contains "test-bin/app/app.ipa" \
"Payload/app.app/PlugIns/stickerpack.appex/sticker_pack.stickerpack/sticker.png"
# TODO(b/120618397): Reenable these assertions.
# assert_zip_contains "test-bin/app/app.ipa" \
# "Payload/app.app/PlugIns/stickerpack.appex/sticker_pack.stickerpack/Info.plist"
# assert_zip_contains "test-bin/app/app.ipa" \
# "Payload/app.app/PlugIns/stickerpack.appex/sticker_pack.stickerpack/sequence.png"
# assert_zip_contains "test-bin/app/app.ipa" \
# "Payload/app.app/PlugIns/stickerpack.appex/sticker_pack.stickerpack/sticker.png"
}

# Tests that a sticker pack application fails to build and emits a reasonable
Expand Down

0 comments on commit a76180f

Please sign in to comment.