6
6
// ***********************************************************************
7
7
8
8
using UnityEngine ;
9
- using UnityEditor ;
10
- using System . IO ;
11
- using System . Collections . Generic ;
12
9
using NUnit . Framework ;
10
+ using UnityEditor . Formats . Fbx . Exporter ;
13
11
14
12
namespace FbxExporters . UnitTests
15
13
{
@@ -36,46 +34,46 @@ void LogNonEmptyString(string name, string str) {
36
34
public void BasicTest ( ) {
37
35
// test Maya integration
38
36
{
39
- var mayaIntegration = new Editor . MayaIntegration ( ) ;
37
+ var mayaIntegration = new MayaIntegration ( ) ;
40
38
41
39
LogNonEmptyString ( "display name" , mayaIntegration . DccDisplayName ) ;
42
40
LogNonEmptyString ( "integration zip path" , mayaIntegration . IntegrationZipPath ) ;
43
41
44
- Assert . IsTrue ( Editor . MayaIntegration . IsHeadlessInstall ( ) == 0 ) ;
42
+ Assert . IsTrue ( MayaIntegration . IsHeadlessInstall ( ) == 0 ) ;
45
43
46
44
LogNonEmptyString ( "module template path" , mayaIntegration . GetModuleTemplatePath ( ) ) ;
47
- LogNonEmptyString ( "package path" , Editor . MayaIntegration . GetPackagePath ( ) ) ;
45
+ LogNonEmptyString ( "package path" , MayaIntegration . GetPackagePath ( ) ) ;
48
46
49
47
LogNonEmptyString ( "export settings path" , mayaIntegration . GetExportSettingsPath ( ) ) ;
50
- LogNonEmptyString ( "package version" , Editor . MayaIntegration . GetPackageVersion ( ) ) ;
48
+ LogNonEmptyString ( "package version" , MayaIntegration . GetPackageVersion ( ) ) ;
51
49
52
50
// check if folder is unzipped at invalid paths
53
51
Assert . IsFalse ( mayaIntegration . FolderAlreadyUnzippedAtPath ( null ) ) ;
54
52
Assert . IsFalse ( mayaIntegration . FolderAlreadyUnzippedAtPath ( "" ) ) ;
55
53
Assert . IsFalse ( mayaIntegration . FolderAlreadyUnzippedAtPath ( "X:/a/b/a/c" ) ) ;
56
54
57
55
// test that the paths don't contain backslashes
58
- Assert . IsFalse ( Editor . MayaIntegration . GetProjectPath ( ) . Contains ( "\\ " ) ) ;
56
+ Assert . IsFalse ( MayaIntegration . GetProjectPath ( ) . Contains ( "\\ " ) ) ;
59
57
Assert . IsFalse ( mayaIntegration . GetExportSettingsPath ( ) . Contains ( "\\ " ) ) ;
60
58
}
61
59
62
60
// test Maya LT integration
63
61
{
64
- var mayaLTIntegration = new Editor . MayaLTIntegration ( ) ;
62
+ var mayaLTIntegration = new MayaLTIntegration ( ) ;
65
63
66
64
// make sure that the values we get are for Maya LT since it inherits a lot from Maya Integration
67
65
Assert . AreEqual ( "Maya LT" , mayaLTIntegration . DccDisplayName ) ;
68
66
}
69
67
70
68
// test 3ds Max integration
71
69
{
72
- var maxIntegration = new Editor . MaxIntegration ( ) ;
70
+ var maxIntegration = new MaxIntegration ( ) ;
73
71
74
72
LogNonEmptyString ( "display name" , maxIntegration . DccDisplayName ) ;
75
73
LogNonEmptyString ( "integration zip path" , maxIntegration . IntegrationZipPath ) ;
76
74
77
75
// check getting absolute path
78
- var absPath = Editor . MaxIntegration . GetAbsPath ( "foo" ) ;
76
+ var absPath = MaxIntegration . GetAbsPath ( "foo" ) ;
79
77
Assert . IsTrue ( System . IO . Path . IsPathRooted ( absPath ) ) ;
80
78
Assert . IsFalse ( absPath . Contains ( "\\ " ) ) ;
81
79
0 commit comments