Skip to content

Commit ec04916

Browse files
committed
Move pkg/generate unit tests to pkg/model
This patch moves all unit tests in `pkg/generate` (tests for the old `generate.Generator`) to `pkg/model`. Also moves all testdata to `pkg/testdata` and update `testutil.NewModelForService` to properly build the test data path for both `pkg/model` and `pkg/generate/code` uni tests
1 parent 3d3e4df commit ec04916

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+24
-21
lines changed

pkg/generate/enum_def_test.go renamed to pkg/model/enum_def_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"sort"

pkg/generate/apigwv2_test.go renamed to pkg/model/model_apigwv2_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/codedeploy_test.go renamed to pkg/model/model_codedeploy_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/dynamodb_test.go renamed to pkg/model/model_dynamodb_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/ec2_test.go renamed to pkg/model/model_ec2_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/ecr_test.go renamed to pkg/model/model_ecr_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/elasticache_test.go renamed to pkg/model/model_elasticache_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/lambda_test.go renamed to pkg/model/model_lambda_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/mq_test.go renamed to pkg/model/model_mq_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

pkg/generate/rds_test.go renamed to pkg/model/model_rds_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
// express or implied. See the License for the specific language governing
1212
// permissions and limitations under the License.
1313

14-
package generate_test
14+
package model_test
1515

1616
import (
1717
"testing"

0 commit comments

Comments
 (0)