(t *testing.T)
| 128 | } |
| 129 | |
| 130 | func TestGetCodemods_DisablesRequestedCodemods(t *testing.T) { |
| 131 | codemods, err := GetCodemods([]string{"timeout-minutes-migration", "network-firewall-migration"}) |
| 132 | require.NoError(t, err) |
| 133 | |
| 134 | var ids []string |
| 135 | for _, codemod := range codemods { |
| 136 | ids = append(ids, codemod.ID) |
| 137 | } |
| 138 | |
| 139 | assert.NotContains(t, ids, "timeout-minutes-migration") |
| 140 | assert.NotContains(t, ids, "network-firewall-migration") |
| 141 | assert.Contains(t, ids, "command-to-slash-command-migration") |
| 142 | } |
| 143 | |
| 144 | func TestGetCodemods_UnknownDisabledCodemodReturnsError(t *testing.T) { |
| 145 | codemods, err := GetCodemods([]string{"not-a-real-codemod"}) |
nothing calls this directly
no test coverage detected